Skip to main content

%SYS.PhoneProviders

Class %SYS.PhoneProviders Extends (%Persistent, %XML.Adaptor, %SYSTEM.Help) [ System = 4 ]

Parameters

EMSSERVICE

Parameter EMSSERVICE [ Internal ] = "Users";

VERSION

Parameter VERSION [ Internal ] = 1;

SOURCECONTROL

Parameter SOURCECONTROL [ Internal ] = {"Revision path: $Id: //iris/2024.3.0/databases/sys/cls/SYS/PhoneProviders.xml#1 $"_$c(13,10)_"Last Change:   $DateTime: 2024/10/02 10:58:11 $"_$c(13,10)_"Changelist #:  $Change: 7247250 $"};

Properties

Name

Property Name As %String [ Required ];

Business name

SMSGateway

Property SMSGateway As %String [ Required ];

DNS name of SMTP-to-SMS gateway

Version

Property Version As %Decimal(SCALE = 1) [ Internal ];

Version number of the record.
Used for Export/Import.

Methods

Exists

ClassMethod Exists(Name As %String, ByRef PhoneProvider As %ObjectHandle, ByRef Status As %Status) As %Boolean

PhoneProvider exists.
This method checks for the existence of a PhoneProvider in the security database.
Parameters:
Name - Name of the PhoneProvider to check existence of
Return values:
If Value of the method = 0 (PhoneProvider does not exist, or some error occured)
PhoneProvider = Null
Status = PhoneProvider "x" does not exist, or other error message

If Value of the method = 1 (PhoneProvider exists)
PhoneProvider = Object handle to PhoneProvider
Status = $$$OK

Export

ClassMethod Export(FileName As %String = "PhoneProvidersExport.xml", ByRef NumExported As %Integer, PhoneProviders As %String = "*") As %Status

This method exports PhoneProvider records to a file in xml format.
Parameters:
Filename - Output file name
NumExported (byref) - Returns number of records exported.
PhoneProviders - Comma separated list of PhoneProviders to export, "*" = All

Get

ClassMethod Get(PhoneProvider As %String, ByRef Properties As %String) As %Status

GetProperties

ClassMethod GetProperties(PhoneProvider As %ObjectHandle, ByRef Properties As %String) As %Status

Get a PhoneProvider's properties.
Gets a PhoneProviders's properties from the security database.
Parameters:
PhoneProvider - Object handle to a PhoneProviders record
Return values:
Properties - See the Get method for more information on properties returned

Import

ClassMethod Import(FileName As %String = "PhoneProvidersExport.xml", ByRef NumImported As %Integer, Flags As %Integer = 0) As %Status

Import PhoneProvider records from an xml file.
Parameters:
FileName - Filename to import PhoneProvider records from
NumImported (byref) - Returns number of records imported
Flags - Control import
Bit 0 - Do not import records, just return count
Note: On failure, no records will be imported

Initialize

ClassMethod Initialize() As %Status [ Internal, ProcedureBlock = 0 ]

Create

ClassMethod Create(Name As %String, ByRef Properties As %String) As %Status

The following methods added to make the UI API consistent between %SYS and EMS

Delete

ClassMethod Delete(Name As %String) As %Status

Modify

ClassMethod Modify(Name As %String, ByRef Properties As %String) As %Status

Modify a PhoneProvider.
Modify an existing PhoneProvider's properties in the security database.
Parameters:
Name - Name of the PhoneProvider to modify
Properties - Array of properties to modify.
See the Get() method for a description of the Properties parameter.
If a specific property is not passed in the properties array, the value is not modified.

StartEMS

ClassMethod StartEMS() As %Status [ Internal ]

%OnAfterSave

Method %OnAfterSave(insert As %Boolean) As %Status [ Internal, Private ]

This callback method is invoked by the %Save method to provide notification that the object is being saved. It is called after the object's data has been successfully written to disk.

insert will be set to 1 if this object is being saved for the first time.

If this method returns an error then the call to %Save will fail.

%OnBeforeSave

Method %OnBeforeSave(insert As %Boolean) As %Status [ Internal, Private, ServerOnly = 1 ]

Caller of %Save must have %Admin_Secure:U.

%OnDelete

ClassMethod %OnDelete(oid As %ObjectIdentity) As %Status [ Internal, Private, ServerOnly = 1 ]

Caller of %Delete must have %Admin_Secure:U.

%OnDeleteId

ClassMethod %OnDeleteId(oid As %ObjectIdentity) As %Status [ Internal, Private, ServerOnly = 1 ]

Caller of %DeleteId must have %Admin_Secure:U.