%Archive.Content
class %Archive.Content extends %Library.RegisteredObject
An Archive Content is an object of source or target of Archive operations (cf. %Archive.Session)Sample script that creates an Archive Content object for a (source) file or files to be archived:
Set ContentOref = ##class(%Archive.Content).%New() Set ContentOref.Name = "File" // description of the content Set ContentOref.RetentionSpec = 0 // a retention period or class name Set Status = ContentOref.AddSource(SourceFilePath1,"Test File 1") // path of the source file and a brief description ("tagname") // and if there are more files to store (as a single content) -- Set Status = ContentOref.AddSource(SourceFilePath2,"Test File 2") // and so on
Set ContentOref = ##class(%Archive.Content).%New() Set Status = ContentOref.DataSink.Insert(TargetFilePath1) // and if the content contains more than one file -- Set Status = ContentOref.DataSink.Insert(TargetFilePath2) // and so on
Property Inventory
Method Inventory
Properties
property Attribute as array of %String;
Optional attributes of the content, in pairs of AttributeName and AttributeValue
Property methods: AttributeBuildValueArray(), AttributeCollectionToDisplay(), AttributeCollectionToOdbc(), AttributeDisplayToCollection(), AttributeDisplayToLogical(), AttributeGet(), AttributeGetObject(), AttributeGetObjectId(), AttributeGetSwizzled(), AttributeIsValid(), AttributeLogicalToDisplay(), AttributeLogicalToOdbc(), AttributeNormalize(), AttributeOdbcToCollection(), AttributeSet(), AttributeSetObject(), AttributeSetObjectId()
property DataSink as list of %String;
a list of targets (file path, %Stream, etc.) for retrieving content from server
Property methods: DataSinkBuildValueArray(), DataSinkCollectionToDisplay(), DataSinkCollectionToOdbc(), DataSinkDisplayToCollection(), DataSinkDisplayToLogical(), DataSinkGet(), DataSinkGetObject(), DataSinkGetObjectId(), DataSinkGetSwizzled(), DataSinkIsValid(), DataSinkLogicalToDisplay(), DataSinkLogicalToOdbc(), DataSinkNormalize(), DataSinkOdbcToCollection(), DataSinkSet(), DataSinkSetObject(), DataSinkSetObjectId()
property DataSource as %String [ MultiDimensional ];
for storing content to server
- DataSource = DataSourceCount
- DataSource(DataSourceID,"TagName") = TagName
- DataSource(DataSourceID,"Source") = Output source (file path, %Stream, etc.)
Property methods: DataSourceDisplayToLogical(), DataSourceGet(), DataSourceIsValid(), DataSourceLogicalToDisplay(), DataSourceLogicalToOdbc(), DataSourceNormalize(), DataSourceSet()
property Name as %String;
An optional, descriptive name for the content
Property methods: NameDisplayToLogical(), NameGet(), NameIsValid(), NameLogicalToDisplay(), NameLogicalToOdbc(), NameNormalize(), NameSet()
property RetentionSpec as %String;
Either a retention period, specified as a number (consisting of only digits) in seconds, or a retention class name
Property methods: RetentionSpecDisplayToLogical(), RetentionSpecGet(), RetentionSpecIsValid(), RetentionSpecLogicalToDisplay(), RetentionSpecLogicalToOdbc(), RetentionSpecNormalize(), RetentionSpecSet()
Methods
method AddSource(DataSource As %RegisteredObject, TagName As %String) as %Status
Specify a data source to export to server
Inherited Members
Inherited Methods
- %AddToSaveSet()
- %ClassIsLatestVersion()
- %ClassName()
- %ConstructClone()
- %DispatchClassMethod()
- %DispatchGetModified()
- %DispatchGetProperty()
- %DispatchMethod()
- %DispatchSetModified()
- %DispatchSetMultidimProperty()
- %DispatchSetProperty()
- %Extends()
- %GetParameter()
- %IsA()
- %IsModified()
- %New()
- %NormalizeObject()
- %ObjectModified()
- %OriginalNamespace()
- %PackageName()
- %RemoveFromSaveSet()
- %SerializeObject()
- %SetModified()
- %ValidateObject()