public static Object getAttributeCaseChecked ( SimpleFeature feature , String field ) { Object attribute = feature . getAttribute ( field ) ; if ( attribute == null ) { attribute = feature . getAttribute ( field . toLowerCase ( ) ) ; if ( attribute != null ) return attribute ; attribute = feature . getAttribute ( field . toUpperCase ( ) ) ; if ( attribute != null ) return attribute ; // alright, last try, search for it SimpleFeatureType featureType = feature . getFeatureType ( ) ; field = findAttributeName ( featureType , field ) ; if ( field != null ) { return feature . getAttribute ( field ) ; } } return attribute ; }
Getter for attributes of a feature .