/** * Process the FQCN attribute * @throws LdapInvalidAttributeValueException */ private String getFqcn( Entry entry, String objectType ) throws LdapInvalidAttributeValueException { // The FQCN Attribute 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 IllegalArgumentException( msg ); } return mFqcn.getString(); }
Attribute mSyntax = entry.get( MetaSchemaConstants.M_SYNTAX_AT ); Attribute mSyntaxLength = entry.get( MetaSchemaConstants.M_LENGTH_AT ); Attribute mEquality = entry.get( MetaSchemaConstants.M_EQUALITY_AT ); Attribute mOrdering = entry.get( MetaSchemaConstants.M_ORDERING_AT ); Attribute mSubstr = entry.get( MetaSchemaConstants.M_SUBSTR_AT ); Attribute mSupAttributeType = entry.get( MetaSchemaConstants.M_SUP_ATTRIBUTE_TYPE_AT ); Attribute mCollective = entry.get( MetaSchemaConstants.M_COLLECTIVE_AT ); Attribute mSingleValued = entry.get( MetaSchemaConstants.M_SINGLE_VALUE_AT ); Attribute mNoUserModification = entry.get( MetaSchemaConstants.M_NO_USER_MODIFICATION_AT ); Attribute mUsage = entry.get( MetaSchemaConstants.M_USAGE_AT );
Attribute byteCode = entry.get( MetaSchemaConstants.M_BYTECODE_AT );
if ( entry.get( SchemaConstants.CN_AT ) == null ) name = entry.get( SchemaConstants.CN_AT ).getString(); if ( entry.get( SchemaConstants.CREATORS_NAME_AT ) == null ) owner = entry.get( SchemaConstants.CREATORS_NAME_AT ).getString(); if ( entry.get( MetaSchemaConstants.M_DISABLED_AT ) != null ) String value = entry.get( MetaSchemaConstants.M_DISABLED_AT ).getString(); value = value.toUpperCase(); isDisabled = value.equals( "TRUE" ); if ( entry.get( MetaSchemaConstants.M_DEPENDENCIES_AT ) != null ) Attribute depsAttr = entry.get( MetaSchemaConstants.M_DEPENDENCIES_AT );
/** * 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 Attribute 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 IllegalArgumentException( 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; }
Attribute byteCode = entry.get( MetaSchemaConstants.M_BYTECODE_AT );
/** * Create a new attributeValue * * @param type The attribute's name (called 'type' in the grammar) */ public void addAttributeType( String type ) throws LdapException { // do not create a new attribute if we have seen this attributeType before if ( getDecorated().getEntry().get( type ) != null ) { currentAttribute = getDecorated().getEntry().get( type ); return; } // fix this to use AttributeImpl(type.getString().toLowerCase()) currentAttribute = new DefaultEntryAttribute( type ); getDecorated().getEntry().put( currentAttribute ); }
Attribute byteCode = entry.get( MetaSchemaConstants.M_BYTECODE_AT );
Attribute mObsolete = entry.get( MetaSchemaConstants.M_OBSOLETE_AT ); Attribute mDescription = entry.get( MetaSchemaConstants.M_DESCRIPTION_AT ); Attribute names = entry.get( MetaSchemaConstants.M_NAME_AT ); Attribute mDisabled = entry.get( MetaSchemaConstants.M_DISABLED_AT ); Attribute xSchema = entry.get( MetaSchemaConstants.X_SCHEMA_AT ); Attribute xNotHumanReadable = entry.get( MetaSchemaConstants.X_NOT_HUMAN_READABLE_AT ); Attribute xReadOnly = entry.get( MetaSchemaConstants.X_READ_ONLY_AT ); Attribute xEnabled = entry.get( MetaSchemaConstants.X_ENABLED_AT );
Attribute mSyntax = entry.get( MetaSchemaConstants.M_SYNTAX_AT );