org.prorefactor.widgettypes
Class Frame

java.lang.Object
  extended by org.prorefactor.treeparser.Symbol
      extended by org.prorefactor.treeparser.Widget
          extended by org.prorefactor.treeparser.FieldContainer
              extended by org.prorefactor.widgettypes.Frame
All Implemented Interfaces:
Xferable, SymbolI, WidgetI

public class Frame
extends FieldContainer


Field Summary
 
Fields inherited from interface org.prorefactor.treeparser.SymbolI
NAME_ORDER
 
Constructor Summary
Frame()
          Only to be used for persistence/serialization.
Frame(java.lang.String name, SymbolScope scope)
          Unlike other symbols, Frames are automatically added to the scope, right here at creation time.
 
Method Summary
 Symbol copyBare(SymbolScope scope)
          Generate a bare-bones copy of this symbol.
 Block getFrameScopeBlock()
           
 int getProgressType()
          Returns TokenTypes.FRAME.
 Block initialize(Block block)
          Initialize the frame and set the frame scope if not done already.
 boolean isInitialized()
          Has this frame been "referenced"? In other words, has it or any of its fields been displayed yet? Has its scope been determined?
 void setFrameScopeBlockExplicitDefault(Block block)
          This should be called for a block with an explicit default.
 Block setFrameScopeUnnamedDefault(Block block)
          This should be called when we need to set a block with this unnamed frame as that block's implicit default.
 void writeXferBytes(DataXferStream out)
          Implement Xferable.
 void writeXferSchema(DataXferStream out)
          Implement Xferable.
 
Methods inherited from class org.prorefactor.treeparser.FieldContainer
addStatement, addSymbol, getAllFields, getAllFieldsAndWidgets, getEnabledFields, getStatementList, lookupFieldOrVar
 
Methods inherited from class org.prorefactor.treeparser.Widget
fullName
 
Methods inherited from class org.prorefactor.treeparser.Symbol
getAllRefsCount, getAsNode, getDefineNode, getIndirectDefineIdNode, getLikeNode, getName, getNumReads, getNumWrites, getScope, isExported, isImported, noteReference, setAsNode, setDefOrIdNode, setLikeNode, setName, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.prorefactor.treeparser.SymbolI
getAllRefsCount, getAsNode, getDefineNode, getIndirectDefineIdNode, getLikeNode, getName, getNumReads, getNumWrites, getScope, isExported, isImported, noteReference, setAsNode, setDefOrIdNode, setLikeNode, setName
 

Constructor Detail

Frame

public Frame()
Only to be used for persistence/serialization.


Frame

public Frame(java.lang.String name,
             SymbolScope scope)
Unlike other symbols, Frames are automatically added to the scope, right here at creation time.

Method Detail

copyBare

public Symbol copyBare(SymbolScope scope)
Description copied from class: Symbol
Generate a bare-bones copy of this symbol. Requires the scope to attach it to as the argument.

Specified by:
copyBare in class Symbol

getFrameScopeBlock

public Block getFrameScopeBlock()

getProgressType

public int getProgressType()
Returns TokenTypes.FRAME.

Specified by:
getProgressType in interface SymbolI
Specified by:
getProgressType in class Symbol

initialize

public Block initialize(Block block)
Initialize the frame and set the frame scope if not done already. Returns the frameScopeBlock.

See Also:
isInitialized()

isInitialized

public boolean isInitialized()
Has this frame been "referenced"? In other words, has it or any of its fields been displayed yet? Has its scope been determined?


setFrameScopeBlockExplicitDefault

public void setFrameScopeBlockExplicitDefault(Block block)
This should be called for a block with an explicit default. i.e. {DO|FOR|REPEAT} WITH FRAME.


setFrameScopeUnnamedDefault

public Block setFrameScopeUnnamedDefault(Block block)
This should be called when we need to set a block with this unnamed frame as that block's implicit default. Returns the block that this unnamed/default frame got scoped to. That would be a REPEAT or FOR block, or else the frame's symbol scope.


writeXferBytes

public void writeXferBytes(DataXferStream out)
                    throws java.io.IOException
Implement Xferable.

Specified by:
writeXferBytes in interface Xferable
Overrides:
writeXferBytes in class FieldContainer
Throws:
java.io.IOException

writeXferSchema

public void writeXferSchema(DataXferStream out)
                     throws java.io.IOException
Implement Xferable.

Specified by:
writeXferSchema in interface Xferable
Overrides:
writeXferSchema in class FieldContainer
Throws:
java.io.IOException


Copyright © 2008 Joanju Software. All Rights Reserved.