public static boolean deleteDuplicatedQualfiier ( Feature feature , String qualifierName ) { ArrayList < Qualifier > qualifiers = ( ArrayList < Qualifier > ) feature . getQualifiers ( qualifierName ) ; Set < String > qualifierValueSet = new HashSet < String > ( ) ; for ( Qualifier qual : qualifiers ) { if ( qual . getValue ( ) != null ) { if ( ! qualifierValueSet . add ( qual . getValue ( ) ) ) { feature . removeQualifier ( qual ) ; return true ; } } } return false ; }
Delete duplicated qualfiier .