@Override protected String getID( DockFactory<?,?,?> factory ) { if( factory == this.factory ) return KNOWN; else return UNKNOWN + super.getID( factory ); }
@Override protected String getID( DockFactory<?,?,?> factory ) { if( factory == this.factory ) return KNOWN; else return UNKNOWN + super.getID( factory ); }
@Override protected String getID( PerspectiveElement element ){ return DockSituation.this.getID( element ); }
/** * Tells what identifier is used for <code>factory</code> in the * {@link DockLayoutComposition}.<br> * This method just calls {@link #getID(DockFactory)}, but * {@link #getID(DockFactory)} is intended for internal use while this * method is intended to be used by clients which read out a {@link DockLayoutComposition}. * @param factory the factory which might be used * @return the identifier * @see #getID(DockFactory) */ public String convertFactoryId( DockFactory<?,?,?> factory ){ return getID( factory ); }
/** * Constructs a new DockSituation and sets some factories which are * used to create new {@link DockElement DockElements}. Please note that this * constructor does not add the default factories, hence it should be used with care. * @param factories the factories */ public DockSituation( DockFactory<?,?,?>...factories ){ for( DockFactory<?,?,?> factory : factories ) this.factories.put( getID( factory ), factory ); }
/** * Adds a factory * @param factory the additional factory */ public void add( DockFactory<?,?,?> factory ){ factories.put( getID( factory ), factory ); }
@Override public String getID( DockElement dockable ){ String key = elementToString.get( dockable ); if( key == null ) return UNKNOWN + super.getID( dockable ); else return KNOWN; }
@Override public String getID( DockElement dockable ){ String key = elementToString.get( dockable ); if( key == null ) return UNKNOWN + super.getID( dockable ); else return KNOWN; }
/** * Gets the identifier that matches <code>element</code> which is part of <code>perspective</code>. * @param element some element whose identifier is searched * @param perspective the owner of <code>element</code> * @return the identifier */ protected String getID( PerspectiveElement element, PredefinedPerspective perspective ){ String key = perspective.get( element ); if( key == null ) return UNKNOWN + super.getID( element ); else return KNOWN; }
/** * Gets the identifier that matches <code>element</code> which is part of <code>perspective</code>. * @param element some element whose identifier is searched * @param perspective the owner of <code>element</code> * @return the identifier */ protected String getID( PerspectiveElement element, PredefinedPerspective perspective ){ String key = perspective.get( element ); if( key == null ) return UNKNOWN + super.getID( element ); else return KNOWN; }
out.writeUTF( getID( factory ) );
return null; String id = getID( element ); DockFactory<DockElement,?,Object> factory = (DockFactory<DockElement,?,Object>)getFactory( id ); if( factory == null )
xfactory.addString( "factory", getID( factory ) ); Path placeholder = info.getPlaceholder(); if( placeholder != null ){