%Studio.SourceControl.Interface
Class %Studio.SourceControl.Interface [ Owner = {%Developer}, System = 3 ]
This provides the interface that Studio uses to talk to the source control class.
Methods
SourceControlClassGet
ClassMethod SourceControlClassGet(namespace As %String) As %String [ Final ]
Return the name of the source control class we should use for this namespace. If we return "" then source control is not enabled in this namespace.
SourceControlClassSet
ClassMethod SourceControlClassSet(val As %String = "", namespace As %String, sys As %Boolean = 0) As %Status [ Final ]
Set the name of the source control class we should use for this namespace. Set the value to "" to disable source control in this namespace. Set the value to $char(0) to remove the source control node for this namespace. This is different to setting it to "", which disables it, as removing the node for this namespace will allow a look through to the default source control class for all namespaces.
Test
ClassMethod Test()
Test the creation of the source control class
SourceControlCreate
ClassMethod SourceControlCreate(Name As %String, Password As %String, ByRef Created As %Boolean, ByRef Flags As %Integer, Output Username As %String, Version As %String = "", ByRef Reload As %String, MainJob As %String = "", ByRef IconStatus As %Integer) As %Status [ Final, NotInheritable ]
Creates an instance of the source control class stored in the local variable '%SourceControl'. This is used by the load/save/compile functions to import/export the routine to the external source control class.
It also returns Created which is true if the source control class was created correctly. Then Flags returns an integer set of flags to determine which dialogs to display in Studio. Studio passes its Version to the server so the server can modify its behavior based on this. The server returns Reload which if "" is set in Studio on a per user basis, but if set to 1 or 0 then this forces the auto reload behavior in Studio to follow this server setting. The MainJob is blank if this process is the main Studio connection, but is the $job of the initial Studio connection job if this is a background job for doing things like find in files, or a big compile. By passing the $job of the main process this background process can co-ordinate with the main job.
normalizeName
ClassMethod normalizeName(InternalName As %String) As %String
Reformat the InternalName to make sure the type is all in upper case
GetStatus
ClassMethod GetStatus(InternalName As %String, ByRef IsInSourceControl As %Boolean, ByRef Editable As %Boolean, ByRef IsCheckedOut As %Boolean, ByRef UserCheckedOut As %String, ByRef Reload As %Boolean) As %Status
Return information about this entity. The Reload parameter is returned by this function and is true if the status check changed the item and so may need to be reloaded.
ExternalName
ClassMethod ExternalName(InternalName As %String) As %String
Returns the external name of this file
IsGenerated
ClassMethod IsGenerated(InternalName As %String) As %Boolean
Return true if this document is generated from some other item
UserAction
ClassMethod UserAction(Type As %Integer, Name As %String, InternalName As %String, SelectedText As %String, ByRef Action As %String, ByRef Target As %String, ByRef Msg As %String, ByRef Reload As %Boolean, ByRef Editable As %Boolean) As %Status
Called when the user makes a change that may require some source control hook interaction
AfterUserAction
ClassMethod AfterUserAction(Type As %Integer, Name As %String, InternalName As %String, Answer As %Integer, Msg As %String = "", ByRef Reload As %Boolean, ByRef Editable As %Boolean) As %Status
Called after Studio brings up its default dialog from calling OnUserAction to tell the server what the answer was
MainMenusExecute
ClassMethod MainMenusExecute(ByRef qHandle As %Binary) As %Status
MainMenusFetch
ClassMethod MainMenusFetch(ByRef qHandle As %Binary, ByRef Row As %List, ByRef AtEnd As %Integer = 0) As %Status
MainMenusClose
ClassMethod MainMenusClose(ByRef qHandle As %Binary) As %Status
MenuItemsExecute
ClassMethod MenuItemsExecute(ByRef qHandle As %Binary, MenuName As %String(MAXLEN=32767), InternalName As %String(MAXLEN=32767) = "", SelectedText As %String(MAXLEN=32767) = "") As %Status
MenuItemsFetch
ClassMethod MenuItemsFetch(ByRef qHandle As %Binary, ByRef Row As %List, ByRef AtEnd As %Integer = 0) As %Status
MenuItemsClose
ClassMethod MenuItemsClose(ByRef qHandle As %Binary) As %Status
ExtensionClassesExecute
ClassMethod ExtensionClassesExecute(ByRef qHandle As %Binary) As %Status
ExtensionClassesFetch
ClassMethod ExtensionClassesFetch(ByRef qHandle As %Binary, ByRef Row As %List, ByRef AtEnd As %Integer = 0) As %Status
ExtensionClassesClose
ClassMethod ExtensionClassesClose(ByRef qHandle As %Binary) As %Status
OnBeforeTimestamp
ClassMethod OnBeforeTimestamp(class As %String(MAXLEN="")) As %Status