Package org.apache.sis.parameter
Class FilteredParameters
java.lang.Object
org.apache.sis.parameter.Parameters
org.apache.sis.parameter.UnmodifiableParameterValueGroup
org.apache.sis.parameter.FilteredParameters
- All Implemented Interfaces:
Serializable
,Cloneable
,LenientComparable
,org.opengis.parameter.GeneralParameterValue
,org.opengis.parameter.ParameterValueGroup
Wraps the given group of parameters, but hiding some parameters.
This is used for hiding contextual parameters such as "semi_major".
Hidden parameters will still be provided if explicitly requested.
This filtered list is unmodifiable.
- Since:
- 1.3
- Version:
- 1.3
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final org.opengis.parameter.GeneralParameterValue[]
The filtered parameter values.private static final long
For cross-version compatibility. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivate
FilteredParameters
(UnmodifiableParameterValueGroup source, org.opengis.parameter.GeneralParameterValue[] filtered) Creates a filtered view of given parameters. -
Method Summary
Modifier and TypeMethodDescription(package private) static UnmodifiableParameterValueGroup
create
(UnmodifiableParameterValueGroup source, Predicate<? super org.opengis.parameter.GeneralParameterDescriptor> filter) Creates a filtered view of given parameters.boolean
equals
(Object object, ComparisonMode mode) Compares the specified object with this parameter for equality.int
hashCode()
Returns a hash value for this parameter.List<org.opengis.parameter.GeneralParameterValue>
values()
Returns a filtered view over the parameter value.Methods inherited from class org.apache.sis.parameter.UnmodifiableParameterValueGroup
addGroup, clone, create, equals, getDescriptor, groups, isKnownImplementation, parameter
Methods inherited from class org.apache.sis.parameter.Parameters
booleanValue, cast, cast, castOrWrap, copy, doubleValue, doubleValue, doubleValueList, getDescriptors, getMandatoryValue, getMemberName, getOrCreate, getParameter, getValue, getValueDomain, intValue, intValueList, isUnmodifiable, parameterIfExist, print, stringValue, toString, unmodifiable, unmodifiable
-
Field Details
-
serialVersionUID
private static final long serialVersionUIDFor cross-version compatibility.- See Also:
-
filtered
private final org.opengis.parameter.GeneralParameterValue[] filteredThe filtered parameter values.
-
-
Constructor Details
-
FilteredParameters
private FilteredParameters(UnmodifiableParameterValueGroup source, org.opengis.parameter.GeneralParameterValue[] filtered) Creates a filtered view of given parameters.
-
-
Method Details
-
create
static UnmodifiableParameterValueGroup create(UnmodifiableParameterValueGroup source, Predicate<? super org.opengis.parameter.GeneralParameterDescriptor> filter) Creates a filtered view of given parameters. This method takes a snapshot of descriptor list using the given filter. No reference to that filter is kept after this method execution.- Parameters:
source
- the group of parameters where values are actually stored.filter
- filter for deciding whether to keep a parameter.- Returns:
- the filtered parameters. May be
source
itself.
-
values
Returns a filtered view over the parameter value.- Specified by:
values
in interfaceorg.opengis.parameter.ParameterValueGroup
- Overrides:
values
in classUnmodifiableParameterValueGroup
-
equals
Compares the specified object with this parameter for equality.- Specified by:
equals
in interfaceLenientComparable
- Overrides:
equals
in classUnmodifiableParameterValueGroup
- Parameters:
object
- the object to compare tothis
.mode
- the strictness level of the comparison.- Returns:
true
if both objects are equal according the given comparison mode.- See Also:
-
hashCode
public int hashCode()Returns a hash value for this parameter.- Overrides:
hashCode
in classUnmodifiableParameterValueGroup
-