Platforms to show: All Mac Windows Linux Cross-Platform

CFObjectMBS.close
Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreFoundation MBS MacCF Plugin 4.1 ✅ Yes ❌ No ❌ No ✅ Yes All
Function: The destructor.
Notes: There is no need to call this method except you want to free all resources of this object now without waiting for Xojo to do it for you.
CFObjectMBS.DeepCopy as CFObjectMBS
Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreFoundation MBS MacCF Plugin ✅ Yes ❌ No ❌ No ✅ Yes All
Function: Creates a deep copy of the CFObject.
Notes: Copies all sub objects if the Object has sub objects (like the Dictionary).
CFObjectMBS.EncodedData as MemoryBlock
Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreFoundation MBS MacCF Plugin 17.1 ✅ Yes ❌ No ❌ No ✅ Yes All
Function: Returns the content of the object and all subobjects as a binary encoded plist file content.
Notes:
Returns nil on any error. For example if you have CFDictionary with keys not being CFStringMBS objects.
You can write this to a plist file.
CFObjectMBS.Equal(o as CFObjectMBS) as boolean
Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreFoundation MBS MacCF Plugin ✅ Yes ❌ No ❌ No ✅ Yes All
Function: Returns true if both CFObjects are equal in type and content.
CFObjectMBS.ReleaseObject
Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreFoundation MBS MacCF Plugin ✅ Yes ❌ No ❌ No ✅ Yes All
Function: Decreases the retain count of this object.
Notes: If the retain count falls below 1, the object is destroyed.
CFObjectMBS.RetainCount as Integer
Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreFoundation MBS MacCF Plugin ✅ Yes ❌ No ❌ No ✅ Yes All
Function: Returns the reference counter of the object.
Example:
dim o as CFObjectMBS
dim s as CFStringMBS

s=NewCFStringMBS("Hello")

MsgBox "s has "+str(s.RetainCount)+" refs in CF"
o=s

MsgBox "o has "+str(o.RetainCount)+" refs in CF"

o.RetainObject

MsgBox "o has "+str(o.RetainCount)+" refs in CF"

o.ReleaseObject

MsgBox "o has "+str(o.RetainCount)+" refs in CF"

o.Close

MsgBox "o has "+str(o.RetainCount)+" refs in CF"
Notes: If the retain count falls below 1, the object is destroyed.
CFObjectMBS.RetainObject
Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreFoundation MBS MacCF Plugin ✅ Yes ❌ No ❌ No ✅ Yes All
Function: Increases the retain count of this object.
Example:
Function CFDateFromCFObject(o as cfobjectMBS) As cfdateMBS
dim d as CFDateMBS

if o<>nil then
if o.Type=kCFDateMBSTypeID then
d=new CFDateMBS
d.Handle=o.Handle
d.RetainObject
end if
end if

Exception
End Function
Notes: If the retain count falls below 1, the object is destroyed.
CFObjectMBS.XML as CFBinaryDataMBS
Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreFoundation MBS MacCF Plugin ✅ Yes ❌ No ❌ No ✅ Yes All
Function: Returns the content of the object and all subobjects as a XML file content.
Example:
// Save a dictionary in a XML file:

dim d as CFMutableDictionaryMBS
dim f as FolderItem
dim t as TextOutputStream

// Create dictionary
d=NewCFMutableDictionaryMBS
// Fill dictionary
d.Add NewCFStringMBS("Key"),NewCFStringMBS("Value")

// get file name
f=GetFolderItem("CF XML Test.txt")

// create file
t=f.CreateTextFile
// Write XML
t.Write d.XML.Str
// close file
t.Close
Notes:
Returns nil on any error. For example if you have CFDictionary with keys not being CFStringMBS objects.
You can write this to a plist file.
CFObjectMBS.XMLdata as String
Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreFoundation MBS MacCF Plugin 19.0 ✅ Yes ❌ No ❌ No ✅ Yes All
Function: Returns the content of the object and all subobjects as a XML file content.
Notes:
Returns empty string on any error. For example if you have CFDictionary with keys not being CFStringMBS objects.
You can write this to a plist file.

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

Feedback: Report problem or ask question.

The biggest plugin in space...


Start Chat