Tabnine Logo
InvalidParameterValueException.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
org.n52.shetland.ogc.ows.exception.InvalidParameterValueException
constructor

Best Java code snippets using org.n52.shetland.ogc.ows.exception.InvalidParameterValueException.<init> (Showing top 20 results out of 315)

origin: 52North/SOS

protected void checkReservedCharacter(String value, String parameterName) throws OwsExceptionReport {
  if (value != null && value.contains(",")) {
    throw new InvalidParameterValueException(parameterName, value)
        .withMessage("The value '%s' contains the reserved parameter ','", value);
  }
}
origin: org.n52.iceland/iceland

public static String checkParameterSingleValue(String value, String name) throws OwsExceptionReport {
  if (checkParameterMultipleValues(value, name).size() == 1) {
    return value;
  } else {
    throw new InvalidParameterValueException(name, value);
  }
}
origin: org.n52.sensorweb.sos/extensions-v20

private void checkResponseFormat(String responseFormat) throws CodedOwsException {
  if (responseFormat == null || responseFormat.isEmpty()) {
    throw new MissingParameterValueException("responseFormat");
  }
  if (!(GetDataAvailabilityConstants.NS_GDA.equals(responseFormat)
      || GetDataAvailabilityConstants.NS_GDA_20.equals(responseFormat))) {
    throw new InvalidParameterValueException("responseFormat", responseFormat);
  }
}
origin: org.n52.sensorweb.sos/hibernate-common

protected Date getDateForTimeIndeterminateValue(IndeterminateValue indeterminateValue, String parameter)
    throws InvalidParameterValueException {
  if (indeterminateValue.isNow()) {
    return new DateTime().toDate();
  }
  throw new InvalidParameterValueException(parameter, indeterminateValue.getValue());
}
origin: org.n52.wps/service

private static OwsExceptionReport duplicateOutput(OwsCode id) {
  return new InvalidParameterValueException().at(OUTPUT).withMessage("Duplicate output definition for output %s",
      id);
}
origin: 52North/SOS

protected void checkTransactionalProcedureID(String procedure, String parameterName) throws OwsExceptionReport {
  if (Strings.isNullOrEmpty(procedure)) {
    throw new MissingProcedureParameterException();
  } else if (!getCache().hasTransactionalObservationProcedure(procedure)) {
    throw new InvalidParameterValueException(parameterName, procedure);
  }
}
origin: 52North/SOS

protected void checkQueryableProcedureID(String procedure, String parameterName) throws OwsExceptionReport {
  if (Strings.isNullOrEmpty(procedure)) {
    throw new MissingProcedureParameterException();
  } else if (!getCache().hasQueryableProcedure(procedure)) {
    throw new InvalidParameterValueException(parameterName, procedure);
  }
}
origin: 52North/SOS

protected void checkTransactionalProcedure(String procedure, String parameterName) throws OwsExceptionReport {
  if (Strings.isNullOrEmpty(procedure)) {
    throw new MissingProcedureParameterException();
  } else if (!getCache().hasTransactionalObservationProcedure(procedure)) {
    throw new InvalidParameterValueException(parameterName, procedure);
  }
}
origin: 52North/SOS

protected void checkQueryableProcedure(String procedure, String parameterName) throws OwsExceptionReport {
  if (Strings.isNullOrEmpty(procedure)) {
    throw new MissingProcedureParameterException();
  } else if (!getCache().hasQueryableProcedure(procedure)) {
    throw new InvalidParameterValueException(parameterName, procedure);
  }
}
origin: 52North/SOS

protected void checkObservationType(String observationType, String parameterName)
    throws OwsExceptionReport {
  if (observationType == null || observationType.isEmpty()) {
    throw new MissingParameterValueException(parameterName);
  } else if (!getCache().hasObservationType(observationType)) {
    throw new InvalidParameterValueException(parameterName, observationType);
  }
}
origin: 52North/SOS

protected void checkResultTemplate(String resultTemplate, String parameterName)
    throws OwsExceptionReport {
  if (resultTemplate == null || resultTemplate.isEmpty()) {
    throw new MissingParameterValueException(parameterName);
  } else if (!getCache().hasResultTemplate(resultTemplate)) {
    throw new InvalidParameterValueException(parameterName, resultTemplate);
  }
}
origin: 52North/SOS

protected boolean checkOnlyRequestableProcedureDescriptionFromats(String format, Enum<?> parameter, boolean mimeTypeAllowed)
    throws CodedOwsException {
  if (Strings.isNullOrEmpty(format)) {
    throw new MissingParameterValueException(parameter);
  } else {
    if (!mimeTypeAllowed && !format.startsWith("http://")) {
      throw new InvalidParameterValueException(parameter, format);
    }
    return getCache().hasRequestableProcedureDescriptionFormat(format) ? true : hasPossibleProcedureDescriptionFormats(format, mimeTypeAllowed);
  }
}
origin: org.n52.wps/service

private Optional<OwsExceptionReport> checkIdentifier(OwsCode id) {
  if (id == null) {
    return Optional.of(new MissingParameterValueException(IDENTIFIER));
  }
  if (!isAll(id) && !getEngine().hasProcessDescription(id)) {
    return Optional.of(new InvalidParameterValueException(IDENTIFIER, id.getValue()));
  }
  return Optional.empty();
}
origin: org.n52.iceland/iceland

public static URI checkParameterSingleURI(String values, String name) throws OwsExceptionReport {
  String value = checkParameterSingleValue(values, name);
  try {
    return new URI(value);
  } catch (URISyntaxException e) {
    throw new InvalidParameterValueException().at(name).causedBy(e)
        .withMessage("Cannot parse provided value '%s' to URI", value);
  }
}
origin: org.n52.wps/service

private static OwsExceptionReport invalidInput(ProcessData input,
    String messageDetail) {
  String id = input.getId().getValue();
  return new InvalidParameterValueException().at(INPUT).withMessage(VALUE_INVALID, id, INPUT, messageDetail);
}
origin: org.n52.wps/service

private static OwsExceptionReport invalidOutput(OutputDefinition output,
    String messageDetail) {
  String id = output.getId().getValue();
  return new InvalidParameterValueException().at(OUTPUT).withMessage(VALUE_INVALID, id, OUTPUT, messageDetail);
}
origin: org.n52.wps/service

@Override
public void validate(AbstractJobIdRequest request) throws OwsExceptionReport {
  JobId jobId = request.getJobId();
  if (jobId == null || jobId.getValue() == null || jobId.getValue().isEmpty()) {
    throw new MissingParameterValueException(JOB_ID);
  }
  if (!getEngine().hasJob(jobId)) {
    throw new InvalidParameterValueException(JOB_ID, jobId.getValue());
  }
}
origin: 52North/SOS

private void createStaticCapabilitiesWithId(GetCapabilitiesRequest request, GetCapabilitiesResponse response) throws
    OwsExceptionReport {
  StaticCapabilities sc = this.capabilitiesExtensionService.getStaticCapabilities(request.getCapabilitiesId());
  if (sc == null) {
    throw new InvalidParameterValueException(GetCapabilitiesParams.CapabilitiesId, request.getCapabilitiesId());
  }
  response.setXmlString(sc.getDocument());
}
origin: 52North/SOS

private void checkResultTemplates(DeleteResultTemplateRequest request, CompositeOwsException exceptions) {
  if (request.isSetResultTemplates()) {
    for (String resultTemplate : request.getResultTemplates()) {
      if (!getCache().hasResultTemplate(resultTemplate)) {
        exceptions.add(new InvalidParameterValueException(
            DeleteResultTemplateConstants.PARAMETERS.resultTemplate,
            resultTemplate));
      }
    }
  }
}
origin: 52North/SOS

private void checkProcedureAndOfferingCombination(InsertSensorRequest request) throws OwsExceptionReport {
  for (SosOffering offering : request.getAssignedOfferings()) {
    if (!offering.isParentOffering() && getCache().getPublishedOfferings().contains(offering.getIdentifier())) {
      throw new InvalidParameterValueException().at(Sos2Constants.InsertSensorParams.offeringIdentifier)
          .withMessage(
              "The offering with the identifier '%s' still exists in this service and it is not allowed to insert more than one procedure to an offering!",
              offering.getIdentifier());
    }
  }
}
org.n52.shetland.ogc.ows.exceptionInvalidParameterValueException<init>

Popular methods of InvalidParameterValueException

  • at
  • withMessage
  • causedBy
  • setStatus

Popular in Java

  • Making http post requests using okhttp
  • getSystemService (Context)
  • getSharedPreferences (Context)
  • scheduleAtFixedRate (Timer)
  • Window (java.awt)
    A Window object is a top-level window with no borders and no menubar. The default layout for a windo
  • URL (java.net)
    A Uniform Resource Locator that identifies the location of an Internet resource as specified by RFC
  • SortedMap (java.util)
    A map that has its keys ordered. The sorting is according to either the natural ordering of its keys
  • Collectors (java.util.stream)
  • Modifier (javassist)
    The Modifier class provides static methods and constants to decode class and member access modifiers
  • JTable (javax.swing)
  • Top 12 Jupyter Notebook Extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now