001package gudusoft.gsqlparser.nodes.oracle;
002
003
004
005import gudusoft.gsqlparser.nodes.TObjectName;
006import gudusoft.gsqlparser.nodes.TObjectNameList;
007import gudusoft.gsqlparser.nodes.TParseTreeNode;
008import gudusoft.gsqlparser.nodes.TParseTreeVisitor;
009
010public class TPhysicalProperties extends TParseTreeNode {
011    private EPhysicalPropertyType physicalPropertyType;
012    private TSegmentAttributesClause segmentAttributesClause;
013
014    public TSegmentAttributesClause getSegmentAttributesClause() {
015        return segmentAttributesClause;
016    }
017
018    public EPhysicalPropertyType getPhysicalPropertyType() {
019        return physicalPropertyType;
020    }
021
022    private TObjectName clusterName;
023    private TObjectNameList clusterColumnList;
024
025    public TObjectNameList getClusterColumnList() {
026        return clusterColumnList;
027    }
028
029    public TObjectName getClusterName() {
030        return clusterName;
031    }
032
033    private EOrganizationType organizationType;
034
035    public EOrganizationType getOrganizationType() {
036        return organizationType;
037    }
038
039    public void init(Object arg1){
040        physicalPropertyType = (EPhysicalPropertyType)arg1;
041    }
042
043    public void init(Object arg1,Object arg2){
044        init(arg1);
045        switch (physicalPropertyType){
046            case ppSegment:
047                segmentAttributesClause = (TSegmentAttributesClause)arg2;
048                break;
049            case ppOrganization:
050                organizationType = (EOrganizationType)arg2;
051                break;
052            case ppCluster:
053                clusterName = (TObjectName)arg2;
054                break;
055        }
056    }
057
058    public void init(Object arg1,Object arg2,Object arg3){
059        init(arg1,arg2);
060        switch (physicalPropertyType){
061            case ppSegment:
062                break;
063            case ppOrganization:
064                switch (organizationType){
065                    case otHeap:
066                        segmentAttributesClause = (TSegmentAttributesClause)arg3;
067                        break;
068                    case otIndex:
069                        segmentAttributesClause = (TSegmentAttributesClause)arg3;
070                        break;
071                }
072                break;
073            case ppCluster:
074                clusterColumnList = (TObjectNameList)arg3;
075                break;
076        }
077    }
078
079    public void accept(TParseTreeVisitor v){
080        v.preVisit(this);
081        v.postVisit(this);
082    }
083
084    public void acceptChildren(TParseTreeVisitor v){
085        v.preVisit(this);
086        v.postVisit(this);
087    }
088
089}