/** * Process the FQCN attribute * @throws LdapInvalidAttributeValueException */ private String getFqcn( Entry entry, String objectType ) throws LdapInvalidAttributeValueException { // The FQCN EntryAttribute mFqcn = entry.get( MetaSchemaConstants.M_FQCN_AT ); if ( mFqcn == null ) { String msg = I18n.err( I18n.ERR_10028, objectType, MetaSchemaConstants.M_FQCN_AT ); LOG.warn( msg ); throw new NullPointerException( msg ); } return mFqcn.getString(); }
/** * Get an OID from an entry. Handles the bad cases (null OID, * not a valid OID, ...) */ private String getOid( Entry entry, String objectType ) throws LdapInvalidAttributeValueException { // The OID EntryAttribute mOid = entry.get( MetaSchemaConstants.M_OID_AT ); if ( mOid == null ) { String msg = I18n.err( I18n.ERR_10005, objectType, MetaSchemaConstants.M_OID_AT ); LOG.warn( msg ); throw new NullPointerException( msg ); } String oid = mOid.getString(); if ( !OID.isOID( oid ) ) { String msg = I18n.err( I18n.ERR_10006, oid ); LOG.warn( msg ); throw new LdapInvalidAttributeValueException( ResultCodeEnum.INVALID_ATTRIBUTE_SYNTAX, msg ); } return oid; }
String val = mObsolete.getString(); schemaObject.setObsolete( val.equalsIgnoreCase( "TRUE" ) ); schemaObject.setDescription( mDescription.getString() ); String val = mDisabled.getString(); schemaObject.setEnabled( !val.equalsIgnoreCase( "TRUE" ) ); String val = mIsReadOnly.getString(); schemaObject.setReadOnly( val.equalsIgnoreCase( "TRUE" ) );
attributeType.setSyntaxOid( mSyntax.getString() ); attributeType.setSyntaxLength( Integer.parseInt( mSyntaxLength.getString() ) ); attributeType.setEqualityOid( mEquality.getString() ); attributeType.setOrderingOid( mOrdering.getString() ); attributeType.setSubstringOid( mSubstr.getString() ); attributeType.setSuperiorOid( mSupAttributeType.getString() ); String val = mCollective.getString(); attributeType.setCollective( val.equalsIgnoreCase( "TRUE" ) ); String val = mSingleValued.getString(); attributeType.setSingleValued( val.equalsIgnoreCase( "TRUE" ) ); String val = mNoUserModification.getString(); attributeType.setUserModifiable( !val.equalsIgnoreCase( "TRUE" ) ); attributeType.setUsage( UsageEnum.getUsage( mUsage.getString() ) );
String time = ((ClonedServerEntry)fileEntry).getOriginalEntry().get( SchemaConstants.CREATE_TIMESTAMP_AT ).getString(); LOG.info( "Load of LDIF file '" + getCanonical( ldifFile ) + "' skipped. It has already been loaded on " + time + "." );
String val = mHumanReadable.getString(); syntax.setHumanReadable( val.toUpperCase().equals( "TRUE" ) );
addAliasIndices( id, new DN( ndnStr ), mods.getString() );
matchingRule.setSyntaxOid( mSyntax.getString() );
addAliasIndices( id, new DN( ndnStr ), mods.getString() );
String type = mTypeObjectClass.getString(); oc.setType( ObjectClassTypeEnum.getClassType( type ) );