deepdiff.core.ConfigProperty Maven / Gradle / Ivy
The newest version!
/*
* Copyright 2011 DeepDiff Contributors
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package deepdiff.core;
/**
* A simple data holder for a three-value property: type, name, and value. All
* of these values are optional. Their meaning is defined entirely by the
* context in which they are used. This class is immutable.
*
* @see Configurable
*/
public final class ConfigProperty {
private final String type;
private final String name;
private final String value;
/**
* Initializes a new ConfigProperty object.
*
* @param type the type for the property, or null for none
* @param name the name for the property, or null for none
* @param value the value for the property, or null for none
*/
public ConfigProperty(String type, String name, String value) {
this.type = type;
this.name = name;
this.value = value;
}
/**
* Returns the name for the property, or null if none was specified
*
* @return the name for the property, or null if none was specified
*/
public String getName() {
return name;
}
/**
* Returns the type for the property, or null if none was specified
*
* @return the type for the property, or null if none was specified
*/
public String getType() {
return type;
}
/**
* Returns the value for the property, or null if none was specified
*
* @return the value for the property, or null if none was specified
*/
public String getValue() {
return value;
}
}