public final class SdfPropertyExtractor<T> extends Object implements PropertyExtractor<T>
Modifier and Type | Method and Description |
---|---|
static SdfPropertyExtractor<Double> |
doubleProp(String propname,
boolean allowMissing) |
T |
extract(StructureRecord mol)
Extract/calculate represented property from a structure.
|
Class<T> |
getExtractedType()
Extracted type.
|
static SdfPropertyExtractor<Integer> |
intProp(String propname,
boolean allowMissing) |
static SdfPropertyExtractor<Long> |
longProp(String propname,
boolean allowMissing) |
static SdfPropertyExtractor<String> |
stringProp(String propname,
boolean allowMissing) |
String |
toString() |
public static SdfPropertyExtractor<Integer> intProp(String propname, boolean allowMissing)
public static SdfPropertyExtractor<Long> longProp(String propname, boolean allowMissing)
public static SdfPropertyExtractor<Double> doubleProp(String propname, boolean allowMissing)
public static SdfPropertyExtractor<String> stringProp(String propname, boolean allowMissing)
public Class<T> getExtractedType()
PropertyExtractor
getExtractedType
in interface PropertyExtractor<T>
public T extract(StructureRecord mol) throws IllegalArgumentException
PropertyExtractor
IllegalArgumentException
is thrown when the property of the represented type can not be
extracted, including the following example cases:
extract
in interface PropertyExtractor<T>
mol
- Input structureIllegalArgumentException
- when the represented type can not be extracted. Implementation note: this is the
expected exception thrown when Chemical Terms are encapsulated and type mismatch surfaces only after execution