Xojo Conferences
MBSOct2019CologneDE

Platforms to show: All Mac Windows Linux Cross-Platform

XMPMetaMBS.ApplyTemplate(WorkingXMP as XMPMetaMBS, template as XMPMetaMBS, actions as Integer)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 11.0 Yes Yes Yes Yes No
Function: Applies an xmp template.

Feedback, Comments & Corrections

XMPMetaMBS.ComposeArrayItemPath(schemaNS as string, arrayName as string, itemIndex as Integer) as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Compose the path expression for an item in an array.
Notes:
schemaNSThe namespace URI for the array. Must not be null or the empty string.
arrayNameThe name of the array. May be a general path expression, must not be an empty string.
itemIndexThe index of the desired item. Arrays in XMP are indexed from 1. The constant kXMP_ArrayLastItem always refers to the last existing array item.
Returns the composed path. This will be of the form <tt>ns:arrayName[i]</tt>, where "ns" is the prefix for schemaNS and "i" is the decimal representation of itemIndex. If the value of itemIndex is kXMP_ArrayLastItem, the path is <tt>ns:arrayName[last()]</tt>.

Feedback, Comments & Corrections

XMPMetaMBS.ComposeFieldSelector(schemaNS as string, arrayName as string, fieldNS as string, fieldName as string, fieldValue as string) as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Compose the path expression to select an alternate item by a field's value.
Notes:
The path syntax allows two forms of "content addressing" that may be used to select an item in an array of alternatives. The form used in ComposeFieldSelector lets you select an item in an array of structs based on the value of one of the fields in the structs. The other form of content addressing is shown in ComposeLangSelector.

For example, consider a simple struct that has two fields, the name of a city and the URI of an FTP site in that city. Use this to create an array of download alternatives. You can show the user a popup built from the values of the city fields. You can then get the corresponding URI as follows:

path=ComposeFieldSelector ( schemaNS, "Downloads", fieldNS, "City", chosenCity)
exists = GetStructField ( schemaNS, path, fieldNS, "URI", uri )

schemaNSThe namespace URI for the array. Must not be null or the empty string.
arrayNameThe name of the array. May be a general path expression, must not be an empty string.
fieldNSThe namespace URI for the field used as the selector. Must not be an empty string.
fieldNameThe name of the field used as the selector. Must be a simple XML name, must not be an empty string. It must be the name of a field that is itself simple.
fieldValueThe desired value of the field.
Returns the string with the composed path. This will be of the form <tt>ns:arrayName[fNS:fieldName='fieldValue']</tt>, where "ns" is the prefix for schemaNS and "fNS" is the prefix for fieldNS.

Feedback, Comments & Corrections

XMPMetaMBS.ComposeLangSelector(schemaNS as string, arrayName as string, langName as string) as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Compose the path expression to select an alternate item by language.
Notes:
The path syntax allows two forms of "content addressing" that may be used to select an item in an array of alternatives. The form used in ComposeLangSelector lets you select an item in an alt-text array based on the value of its <tt>xml:lang</tt> qualifier. The other form of content addressing is shown in ComposeFieldSelector.

ComposeLangSelector does not supplant SetLocalizedText or GetLocalizedText.
They should generally be used, as they provide extra logic to choose the appropriate language and maintain consistency with the 'x-default' value. ComposeLangSelector gives you an path expression that is explicitly and only for the language given in the langName parameter.

schemaNSThe namespace URI for the array. Must not be null or the empty string.
arrayNameThe name of the array. May be a general path expression, must not be an empty string.
langNameThe RFC 3066 code for the desired language.
Returns the composed path. This will be of the form <tt>ns:arrayName[\@xml:lang='langName']</tt>, where "ns" is the prefix for schemaNS.

Feedback, Comments & Corrections

XMPMetaMBS.ComposeQualifierPath(schemaNS as string, structName as string, qualNS as string, qualName as string) as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Compose the path expression for a qualifier.
Notes:
schemaNS The namespace URI for the property to which the qualifier is attached. Must not be an empty string.
propName The name of the property to which the qualifier is attached. May be a general path expression, must not be an empty string.
qualNS The namespace URI for the qualifier. May be an empty string if the qualifier is in the XML empty namespace.
qualName The name of the qualifier. Must be a simple XML name, must not be an empty string.
Returns the composed path. This will be of the form <tt>ns:propName/?qNS:qualName</tt>, where "ns" is the prefix for schemaNS and "qNS" is the prefix for qualNS.

Feedback, Comments & Corrections

XMPMetaMBS.ComposeStructFieldPath(schemaNS as string, structName as string, fieldNS as string, fieldName as string) as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Compose the path expression for a field in a struct.
Notes:
schemaNSThe namespace URI for the struct. Must not be null or the empty string.
structNameThe name of the struct. May be a general path expression, must not be an empty string.
fieldNSThe namespace URI for the field. Must not be an empty string.
fieldNameThe name of the field. Must be a simple XML name, must not be an empty string.
Returns the composed path. This will be of the form <tt>ns:structName/fNS:fieldName</tt>, where "ns" is the prefix for schemaNS and "fNS" is the prefix for fieldNS.

Feedback, Comments & Corrections

XMPMetaMBS.ConvertFromBool(value as boolean) as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Convert from Boolean to string.

Feedback, Comments & Corrections

XMPMetaMBS.ConvertFromDate(value as XMPDateTimeMBS) as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Convert from date/time to string.

Feedback, Comments & Corrections

XMPMetaMBS.ConvertFromFloat(value as Double, format as string) as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Convert from floating point to string.
Notes: format: Optional C sprintf format for the conversion. Defaults to "%f".

Feedback, Comments & Corrections

XMPMetaMBS.ConvertFromInt(value as Integer, format as string) as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Convert from integer to string.
Notes: format: Optional C sprintf format for the conversion. Defaults to "%d".

Feedback, Comments & Corrections

XMPMetaMBS.ConvertFromInt64(value as Int64, format as string) as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Convert from integer to string.
Notes: format: Optional C sprintf format for the conversion. Defaults to "%d".

Feedback, Comments & Corrections

XMPMetaMBS.ConvertToBool(value as string) as boolean
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Convert from string to Boolean.

Feedback, Comments & Corrections

XMPMetaMBS.ConvertToDate(value as string) as XMPDateTimeMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Convert from string to date/time.

Feedback, Comments & Corrections

XMPMetaMBS.ConvertToFloat(value as string) as Double
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Convert from string to floating point.

Feedback, Comments & Corrections

XMPMetaMBS.ConvertToInt(value as string) as Integer
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Convert from string to integer.

Feedback, Comments & Corrections

XMPMetaMBS.ConvertToInt64(value as string) as Int64
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Convert from string to 64 bit integer.

Feedback, Comments & Corrections

XMPMetaMBS.CurrentDateTime as XMPDateTimeMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Current date and time as a XMPDateTimeMBS object.
Notes: Returns nil on any error.

Feedback, Comments & Corrections

XMPMetaMBS.DecodeFromBase64(text as string) as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Decode from Base64 encoded string to raw data.
Example:
dim x as XMPMetaMBS
x=new XMPMetaMBS
MsgBox x.DecodeFromBase64("dGVzdA==") // test
Notes: This is a global method which does not need a valid handle.

Feedback, Comments & Corrections

XMPMetaMBS.DeleteNamespace(namespaceURI as string)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Deletes a namespace from the registry.
Notes:
Not implemented?

Does nothing if the URI is not registered, or if the parameter is null or the empty string.

namespaceURI: The URI for the namespace.

Feedback, Comments & Corrections

XMPMetaMBS.DumpNamespaces(output as XMPTextOutputMBS) as Integer
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: DumpNamespaces dumps the list of registered namespace URIs and prefixes.
Notes:
This is a global method which does not need a valid handle.
Returns status code. (0=success and -1=error)

Feedback, Comments & Corrections

XMPMetaMBS.EncodeToBase64(text as string) as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Convert from raw data to Base64 encoded string.
Example:
dim x as XMPMetaMBS
x=new XMPMetaMBS
MsgBox x.EncodeToBase64("test") // dGVzdA==
Notes: This is a global method which does not need a valid handle.

Feedback, Comments & Corrections

XMPMetaMBS.GetNamespacePrefix(namespaceURI as string, byref namespacePrefix as string) as boolean
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Obtain the prefix for a registered namespace URI.
Notes:
It is not an error if the namespace URI is not registered. The output namespacePrefix string is "" if the namespace URI is not registered.

Parameters:
namespaceURIThe URI for the namespace. Must not be null or the empty string.
namespacePrefixReturns the prefix registered for this URI, with a terminating ':'.

Returns true if the namespace URI is registered.

This is a global method which does not need a valid handle.

Feedback, Comments & Corrections

XMPMetaMBS.GetNamespaceURI(namespacePrefix as string, byref namespaceURI as string) as boolean
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Obtain the URI for a registered namespace prefix.
Notes:
It is not an error if the namespace prefix is not registered. The output namespaceURI string is "" if the namespace prefix is not registered.

Parameters:
namespacePrefixThe prefix for the namespace. Must not be "".
namespaceURIReturns the URI registered for this prefix.

Returns true if the namespace prefix is registered.

This is a global method which does not need a valid handle.

Feedback, Comments & Corrections

XMPMetaMBS.GetVersionInfo as XMPVersionInfoMBS
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Retrieves runtime version information.

Feedback, Comments & Corrections

XMPMetaMBS.GlobalOptions as Integer
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Sets or retrieves the set of global option flags.
Notes: (Read and Write computed property)

Feedback, Comments & Corrections

XMPMetaMBS.RegisterNamespace(namespaceURI as string, suggestedPrefix as string, byref registeredPrefix as string) as boolean
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
shared method XMP MBS XMP Plugin 9.4 Yes Yes Yes Yes No
Function: Register a namespace URI with a suggested prefix.
Example:
dim x as new XMPMetaMBS
dim registeredPrefix as string

call x.RegisterNamespace ("xwnv", "xwnv", registeredPrefix)

x.SetProperty "xwnv","MZSTID","test"

MsgBox x.SerializeToBuffer
Notes:
It is not an error if the URI is already registered, no matter what the prefix is. If the URI is not registered but the suggested prefix is in use, a unique prefix is created from the suggested one. The actual registeed prefix is always returned. The function result tells if the registered prefix is the suggested one.

Parameters:
namespaceURIThe URI for the namespace. Must be a valid XML URI.
suggestedPrefixThe suggested prefix to be used if the URI is not yet registered. Must be a valid XML name.
registeredPrefixReturns the prefix actually registered for this URI.

Returns true if the registered prefix matches the suggested prefix.

Note: No checking is presently done on either the URI or the prefix.

This is a global method which does not need a valid handle.

Feedback, Comments & Corrections

The items on this page are in the following plugins: MBS XMP Plugin.




Links
MBS Xojo tutorial videos