%Compiler.COS.Refactor

class %Compiler.COS.Refactor extends %Compiler.COS.Traveler

Property Inventory (Including Private)

Method Inventory (Including Private)

Properties

property changed as %Boolean;
Property methods: changedDisplayToLogical(), changedGet(), changedIsValid(), changedLogicalToDisplay(), changedNormalize(), changedSet()
property className as %String;
Property methods: classNameDisplayToLogical(), classNameGet(), classNameIsValid(), classNameLogicalToDisplay(), classNameLogicalToOdbc(), classNameNormalize(), classNameSet()
property cmname as %Binary;
Property methods: cmnameGet(), cmnameIsValid(), cmnameSet()
property ctind as %Integer;
Property methods: ctindDisplayToLogical(), ctindGet(), ctindIsValid(), ctindLogicalToDisplay(), ctindNormalize(), ctindSet()
property lhs as %String;
Property methods: lhsDisplayToLogical(), lhsGet(), lhsIsValid(), lhsLogicalToDisplay(), lhsLogicalToOdbc(), lhsNormalize(), lhsSet()
property lnum as %Integer;
Property methods: lnumDisplayToLogical(), lnumGet(), lnumIsValid(), lnumLogicalToDisplay(), lnumNormalize(), lnumSet()
property methName as %String;
Property methods: methNameDisplayToLogical(), methNameGet(), methNameIsValid(), methNameLogicalToDisplay(), methNameLogicalToOdbc(), methNameNormalize(), methNameSet()
property pair as %ObjectHandle;
Property methods: pairGet(), pairIsValid(), pairSet()
property propName as %String;
Property methods: propNameDisplayToLogical(), propNameGet(), propNameIsValid(), propNameLogicalToDisplay(), propNameLogicalToOdbc(), propNameNormalize(), propNameSet()
property scname as %String;
Property methods: scnameDisplayToLogical(), scnameGet(), scnameIsValid(), scnameLogicalToDisplay(), scnameLogicalToOdbc(), scnameNormalize(), scnameSet()
property smname as %String;
Property methods: smnameDisplayToLogical(), smnameGet(), smnameIsValid(), smnameLogicalToDisplay(), smnameLogicalToOdbc(), smnameNormalize(), smnameSet()
property sqlTableNameList as %String;
Property methods: sqlTableNameListDisplayToLogical(), sqlTableNameListGet(), sqlTableNameListIsValid(), sqlTableNameListLogicalToDisplay(), sqlTableNameListLogicalToOdbc(), sqlTableNameListNormalize(), sqlTableNameListSet()
property ssqlname as %String;
Property methods: ssqlnameDisplayToLogical(), ssqlnameGet(), ssqlnameIsValid(), ssqlnameLogicalToDisplay(), ssqlnameLogicalToOdbc(), ssqlnameNormalize(), ssqlnameSet()
property tcname as %String;
Property methods: tcnameDisplayToLogical(), tcnameGet(), tcnameIsValid(), tcnameLogicalToDisplay(), tcnameLogicalToOdbc(), tcnameNormalize(), tcnameSet()
property tmname as %String;
Property methods: tmnameDisplayToLogical(), tmnameGet(), tmnameIsValid(), tmnameLogicalToDisplay(), tmnameLogicalToOdbc(), tmnameNormalize(), tmnameSet()
property tsqlname as %String;
Property methods: tsqlnameDisplayToLogical(), tsqlnameGet(), tsqlnameIsValid(), tsqlnameLogicalToDisplay(), tsqlnameLogicalToOdbc(), tsqlnameNormalize(), tsqlnameSet()
property type as %String;
Property methods: typeDisplayToLogical(), typeGet(), typeIsValid(), typeLogicalToDisplay(), typeLogicalToOdbc(), typeNormalize(), typeSet()

Methods

classmethod ChangeCSList(ByRef cslist As %String, oldName As %String, newName As %String, bNormalize As %Boolean, context As %String = "") as %Boolean [ Language = objectscript ]
classmethod ChangeClName(oldName As %String, newName As %String, className As %String, ByRef tempName As %String, ByRef storagechanged As %Boolean, bDeleteStorage As %Boolean = 0) as %Status [ Language = objectscript ]
The method ChangeClName is used for changing a class name. Arguments: oldName - existing class name, newName - new class name, className - class to be processed, tempName - name of generated clas,s storagechanged - indicate whether storage was modified. In order to replace encounters of the class A to the class B in the class C, the call should be ChangeClName(A, B, C, .tempName, .storagechanged) As a result of this call a new class (with a name returned in tempName) will be created (but not compiled).
classmethod ChangeClassNameClose(ByRef qHandle As %Binary) as %Status [ Language = objectscript ]
classmethod ChangeClassNameExecute(ByRef qHandle As %Binary, oldName As %String, newName As %String, className As %String, ByRef tempName As %String, ByRef storagechanged As %Boolean) as %Status [ Language = objectscript ]
classmethod ChangeClassNameFetch(ByRef qHandle As %Binary, ByRef Row As %List, ByRef AtEnd As %Integer = 0) as %Status [ Language = objectscript ]
classmethod ChangeMemName(oldName As %String, newName As %String, memclassName As %String, className As %String, ByRef tempName As %String, ByRef storagechanged As %Boolean, sqlName="", bNewSlot As %Boolean = 0) as %Status [ Language = objectscript ]
The method ChangeMemName is used for changing a member name (either a property or a method). Arguments: oldName - existing member name, newName - new member name, memclassName - the class name of a property that is being changed, className - class to be processed, tempName - name of generated clas,s storagechanged - indicate whether storage was modified. In order to replace encounters of the member Z.A to Z.B in the class C, the call should be ChangeMemName(A, B, Z, C, .tempName, .storagechanged) As a result of this call a new class (with a name returned in tempName) will be created (but not compiled).
classmethod ChangeMemberNameClose(ByRef qHandle As %Binary) as %Status [ Language = objectscript ]
classmethod ChangeMemberNameExecute(ByRef qHandle As %Binary, oldName As %String, newName As %String, memclassName As %String, className As %String, ByRef tempName As %String, ByRef storagechanged As %Boolean, sqlName As %String = "") as %Status [ Language = objectscript ]
classmethod ChangeMemberNameFetch(ByRef qHandle As %Binary, ByRef Row As %List, ByRef AtEnd As %Integer = 0) as %Status [ Language = objectscript ]
classmethod ChangeMultClassNameClose(ByRef qHandle As %Binary) as %Status [ Language = objectscript ]
classmethod ChangeMultClassNameExecute(ByRef qHandle As %Binary, oldName As %String, newName As %String, projectName As %String) as %Status [ Language = objectscript ]
classmethod ChangeMultClassNameFetch(ByRef qHandle As %Binary, ByRef Row As %List, ByRef AtEnd As %Integer = 0) as %Status [ Language = objectscript ]
classmethod ChangeMultMemberNameClose(ByRef qHandle As %Binary) as %Status [ Language = objectscript ]
classmethod ChangeMultMemberNameExecute(ByRef qHandle As %Binary, oldName As %String, newName As %String, memclassName As %String, projectName As %String, sqlName As %String = "") as %Status [ Language = objectscript ]
classmethod ChangeMultMemberNameFetch(ByRef qHandle As %Binary, ByRef Row As %List, ByRef AtEnd As %Integer = 0) as %Status [ Language = objectscript ]
classmethod GetMemberOrigin(memberName As %String, className As %String) as %String [ Language = objectscript ]
classmethod GetSubclasses(classname As %String) as %Binary [ Language = objectscript ]
classmethod GetTableList(classnamelist As %Binary) as %Binary [ Language = objectscript ]
classmethod NormalizeClName(clname As %String, context As %String) as %String [ Language = objectscript ]
classmethod RefactorStorageProperty(pClassname As %String, pPropName As %String, pNewName As %String, pNewSlot As %Boolean = 0, ByRef pChanged As %Boolean, pSave As %Boolean = 1) as %String [ Language = objectscript ]
RefactorStorageProperty takes a classname, property name, and a new property name and changes the name of the property to the new name everywhere in the storage definition. The pNewSlot argument means if pNewSlot=1, don't overwrite the current property storage data location, but provide a new data slot with the new name. The pChanged argument is passed by reference and will be set to 1 if any change is made to any Storage defined for this class. It will be 0 if no changes are made. Returns %Status value
classmethod RenameSqlField(ByRef sql As %String, ByRef nuq As %String, ffn As %String, nuf As %String, sch As %String, tab As %String) as %Library.Status [ Language = objectscript ]
In the SQL text array (by ref) .sql(1:sql)=line, find all occurrences, if any, of field ffn from the table specified by sch=$LB(schema) and tab=$LB(table), and replace them with nuf in the result array (by ref) .nuq(1:nuq)=line , returns %Status
classmethod RenameSqlFieldLbst(ByRef sql As %String, ByRef nuq As %String, ffn As %String, nuf As %String, lbst As %String, ByRef pChanged As %Boolean, pClassname As %String = "") as %Library.Status [ Language = objectscript ]
In the SQL text array (by ref) .sql(1:sql)=line, find all occurrences, if any, of field ffn from the tables specified by lbst=$LB(schema.table), and replace them with nuf in the result array (by ref) .nuq(1:nuq)=line , pChanged=0/1 (by ref) indicates whether anything changed, return %Status. pClassname is the class name the sql statement came from, if any, and its package name is used as the packages argument to comp^%qaqqt
classmethod RenameSqlTable(ByRef sql As %String, ByRef nuq As %String, sntn As %String, nust As %String, ByRef pChanged As %Boolean, pClassname As %String = "") as %Library.Status [ Language = objectscript ]
In the SQL text array (by ref) .sql(1:sql)=line, find all occurrences, if any, of [schema.]table sntn=schema.table, and replace them with the new schema.table nust in the result array (by ref) .nuq(1:nuq)=line , pChanged=0/1 (by ref) indicates whether anything changed, return %Status. pClassname is the class name the sql statement came from, if any, and its package name is used as the packages argument to comp^%qaqqt
method oneClass(ByRef tempName As %String, bsave As %Boolean = 1, ByRef storagechanged As %Boolean, bNewSlot As %Boolean = 0, bDeleteStorage As %Boolean = 0) as %Status [ Language = objectscript ]
method oneClassold() as %Status [ Language = objectscript ]
method replaceClassName(parseTree As %Compiler.Util.ParseTree, newname As %Binary, nodePtr As %Integer, parentPtr As %Integer, ann As %String) [ Language = objectscript ]
method replaceMemberName(parseTree As %Compiler.Util.ParseTree, newname As %Binary, nodePtr As %Integer) [ Language = objectscript ]
method rf(ByRef source As %RawString, pPackage As %RawString = "", ByRef code As %RawString, ByRef warning As %Status = 1, sqlContext As %Integer = 0) as %Status [ Language = objectscript ]
method v1(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: PlainBlock(1): child list-Line NOT GENERATED - you MUST run MakeIndexRoutine and MakeDefsInclude if you edit this Used by %CPT.HPT.* classes. next free nodetypes: 98 PROGRAM STRUCTURE
method v10(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: UnknownPreProcessorCommand(10): ann string Snarf:1
method v11(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: CommandSET(11): ann keyword CommandName:1, optional child PostCondition-Expression:1, optional child Arguments-CommandSETArguments:2 SET COMMAND
method v12(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: CommandSETArguments(12): child list-CommandSETArgument
method v13(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: CommandSETArgument(13): child Lhs-CommandSETArgLhs:1, child Rhs-Expression:2
method v14(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: CommandSETArgLhs(14): ann bool IsMultiple:1, child list-SETTarget
method v2(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: PlainLine(2): optional ann name Label:1, optional child ListFormals:1, optional child Body-LineBody:2 CODE LINES
method v32(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: ObjectRef(32): child ObjectRefBase:1, optional child ListMemberRefs:2
method v33(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: ListMemberRefs(33): child list-MemberRef nodeclass ObjectRefBase: Term | PPClass | DotDotBase | ParenObjectRefBase note: HPT only supports the following sorts of Term as an object base: LvnRef, ParenExpr, SystemVar, PPFuncSUPER (just to confirm: ObjectRef won't appear here either)
method v34(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: MemberRef(34): ann name MemberName:1, optional child ActualParameters:1, ann enum MemberType:2 enum MemberType: Method:1, Property:2, Unknown:3, Parameter:4 For a Parameter :- 1. The MemberName *does* include the "#" - this is so that absent-minded clients don't treat it as a method/property. 2. The ActualParameters will always be absent.
method v35(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: PPClass(35): ann keyword ClassKeywordName:1, child ListClassNameComponents:1
method v36(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: ClassNameComponent(36): ann name Name:1
method v37(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: DotDotBase(37): child MemberRef:1
method v38(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: ActualParameters(38): child list-ActualParameter
method v41(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: ListClassNameComponents(41): child list-ClassNameComponent NAMES
method v5(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: Expression(5): child Lhs-ExprOrTerm:1, optional ann keyword DyOp:1, optional child Rhs-ExprOrTerm:2
method v62(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: Embedding(62): ann string Language:1, ann string Opener:2, ann string Body:3, ann string BodyExtent:4, ann string Closer:5 nodeclass LineElement: Command | Embedding EMBEDDING LINES the Body has linefeed ($Char(10)) characters between lines the BodyExtent has the format $ListBuild(startline,startcol,endline,endcol) .. line/column numbers start at 1 .. endline/endcol is the position of the last character in the Body
method v9(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
LvnRef(9): ann name Name:1, ann enum LvnType:2, optional child Subscripts:1 LOCAL/GLOBAL VARIABLES enum LvnType: Private:1, Public:2, Parameter:3
method v97(parseTree As %Compiler.Util.ParseTree, visit As %Integer, nodePtr As %Integer, parentPtr As %Integer) [ Language = objectscript ]
Inherited description: SQLField(97): ann keyword FieldName:1, optional ann keyword Star:2, optional ann keyword TriggerQualifier:3 Other A SQLField will only be recognized by the parser if IPARSE_COS_SQLFIELDS or IPARSE_COS_SQLTRIGGER is set - 'Moniker' argument for those flags: "!FLAGS+2" and "!FLAGS+4" The TriggerQualifier part needs IPARSE_COS_SQLTRIGGER ("!FLAGS+4") The 'Star' annotation is to aid accurate regeneration and should be ignored by parse tree scanners

Queries

query ChangeClassName(oldName As %String, newName As %String, className As %String, ByRef tempName As %String, ByRef storagechanged As %Boolean)
Selects TYPE As %String, CLASSNAME As %String, OLDMEMBERNAME As %String, NEWMEMBERNAME As %String, LINENUMBER As %Integer, OPERATION As %Integer, LINECONTENT As %String
query ChangeMemberName(oldName As %String, newName As %String, memclassName As %String, className As %String, ByRef tempName As %String, ByRef storagechanged As %Boolean, sqlName As %String)
Selects TYPE As %String, CLASSNAME As %String, OLDMEMBERNAME As %String, NEWMEMBERNAME As %String, LINENUMBER As %Integer, OPERATION As %Integer, LINECONTENT As %String
query ChangeMultClassName(oldName As %String, newName As %String, projectName As %String)
Selects CLASSNAME As %String, ERROR As %Integer, MESSAGE As %String
query ChangeMultMemberName(oldName As %String, newName As %String, memclassName As %String, projectName As %String, sqlName As %String)
Selects CLASSNAME As %String, ERROR As %Integer, MESSAGE As %String

Inherited Members

Inherited Properties (Including Private)

Inherited Methods (Including Private)

Feedback