Examples of SchemaWrapper


Examples of org.apache.directory.studio.schemaeditor.view.wrappers.SchemaWrapper

     * @param at
     *      the added attribute type
     */
    public void attributeTypeAddedFlatPresentation( AttributeTypeImpl at )
    {
        SchemaWrapper schemaWrapper = ( SchemaWrapper ) getWrapper( Activator.getDefault().getSchemaHandler()
            .getSchema( at.getSchema() ) );
        if ( schemaWrapper != null )
        {
            AttributeTypeWrapper atw = null;
            int group = store.getInt( PluginConstants.PREFS_SCHEMA_VIEW_GROUPING );
            if ( group == PluginConstants.PREFS_SCHEMA_VIEW_GROUPING_FOLDERS )
            {
                for ( TreeNode child : schemaWrapper.getChildren() )
                {
                    if ( ( ( Folder ) child ).getType() == FolderType.ATTRIBUTE_TYPE )
                    {
                        atw = new AttributeTypeWrapper( at, child );
                        break;
View Full Code Here

Examples of org.apache.directory.studio.schemaeditor.view.wrappers.SchemaWrapper

     * @param oc
     *      the added object class
     */
    public void objectClassAddedFlatPresentation( ObjectClassImpl oc )
    {
        SchemaWrapper schemaWrapper = ( SchemaWrapper ) getWrapper( Activator.getDefault().getSchemaHandler()
            .getSchema( oc.getSchema() ) );
        if ( schemaWrapper != null )
        {
            ObjectClassWrapper ocw = null;
            int group = store.getInt( PluginConstants.PREFS_SCHEMA_VIEW_GROUPING );
            if ( group == PluginConstants.PREFS_SCHEMA_VIEW_GROUPING_FOLDERS )
            {
                for ( TreeNode child : schemaWrapper.getChildren() )
                {
                    if ( ( ( Folder ) child ).getType() == FolderType.OBJECT_CLASS )
                    {
                        ocw = new ObjectClassWrapper( oc, child );
                        break;
View Full Code Here

Examples of org.apache.directory.studio.schemaeditor.view.wrappers.SchemaWrapper

     * @param schema
     *      the removed schema
     */
    private void schemaRemovedFlatPresentation( Schema schema )
    {
        SchemaWrapper sw = ( SchemaWrapper ) getWrapper( schema );
        if ( sw != null )
        {
            sw.getParent().removeChild( sw );
            elementsToWrappersMap.remove( schema, sw );
            removeRecursiveChildren( sw );
        }
    }
View Full Code Here

Examples of org.apache.directory.studio.schemaeditor.view.wrappers.SchemaWrapper

     *
     * @param schema
     */
    public void addSchemaFlatPresentation( Schema schema )
    {
        SchemaWrapper schemaWrapper = new SchemaWrapper( schema, root );
        root.addChild( schemaWrapper );
        elementsToWrappersMap.put( schema, schemaWrapper );

        int group = store.getInt( PluginConstants.PREFS_SCHEMA_VIEW_GROUPING );
        if ( group == PluginConstants.PREFS_SCHEMA_VIEW_GROUPING_FOLDERS )
        {
            Folder atFolder = new Folder( FolderType.ATTRIBUTE_TYPE, schemaWrapper );
            schemaWrapper.addChild( atFolder );

            for ( AttributeTypeImpl attributeType : schema.getAttributeTypes() )
            {
                AttributeTypeWrapper atw = new AttributeTypeWrapper( attributeType, atFolder );
                atw.getParent().addChild( atw );
                elementsToWrappersMap.put( attributeType, atw );
            }

            Folder ocFolder = new Folder( FolderType.OBJECT_CLASS, schemaWrapper );
            schemaWrapper.addChild( ocFolder );

            for ( ObjectClassImpl objectClass : schema.getObjectClasses() )
            {
                ObjectClassWrapper ocw = new ObjectClassWrapper( objectClass, ocFolder );
                ocw.getParent().addChild( ocw );
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.