Show / Hide Table of Contents

Class EabEntry

Reads and writes entries from the email address book. The class is also used when you want to synchronize the address book using DBI.

Syntax
Examples
EabEntry e;

e.load(15);
print(e.getValue("sms"));
e.setValue("name", "test");

Constructors

EabEntry()

Initializes a new instance of the EabEntry class.

Declaration
EabEntry
Examples
EabEntry e;

e.load(15);
print(e.getValue("sms"));
e.setValue("name", "test");

Methods

delete()

Deletes the current address book entry from the database.

Declaration
Void delete()
Returns
Type Description
Void
Examples
EabEntry e;

e.load(15);
print(e.getValue("sms"));
e.setValue("name", "test");

getValue(String)

Gets the value of the given field in the EabEntry instance.

Declaration
String getValue(String field)
Parameters
Type Name Description
String field

The name of the field.

Returns
Type Description
String

The value of the field.

Remarks

Available fields:

  • name
  • email
  • sms
  • folderId
  • dbi_agent_id
  • dbi_key
  • dbi_last_syncronized
  • dbi_last_modified
  • dbi_delete
Examples
EabEntry eab;

Bool b = eab.load(15);
print(b.toString());

eab.setValue("name", "test");

load(Integer)

Loads an entry from the address book with the specified ID.

Declaration
Bool load(Integer id)
Parameters
Type Name Description
Integer id

ID of the entry to load.

Returns
Type Description
Bool

True if loading var successful; otherwise, false.

Examples
EabEntry eab;

Bool b = eab.load(15);
print(b.toString());

loadFromAgentAndKey(Integer,String)

Used in conjunction with DBI. Load an entry with the specified key from the specified agent.

Declaration
Bool loadFromAgentAndKey(Integer id, String key)
Parameters
Type Name Description
Integer id

ID of the agent this EAB entry belongs to

String key

The external key for the EAB entry.

Returns
Type Description
Bool

True if loading var successful; otherwise, false.

Examples
EabEntry e;

e.load(15);
print(e.getValue("sms"));
e.setValue("name", "test");

save()

Saves the current address book entry. If you did not load an existing entry, a new entry will be created; otherwise, it will update the loaded entry.

Declaration
Integer save()
Returns
Type Description
Integer

ID of the saved entry.

Examples
EabEntry e;

e.load(15);
print(e.getValue("sms"));
e.setValue("name", "test");

setValue(String,String)

Sets the value of the given field in the EabEntry instance.

Declaration
Void setValue(String name, String value)
Parameters
Type Name Description
String name

The name of the field.

String value

The value to set.

Returns
Type Description
Void
Remarks

Available fields:

  • name
  • email
  • sms
  • folderId
  • dbi_agent_id
  • dbi_key
  • dbi_last_syncronized
  • dbi_last_modified
  • dbi_delete
Examples
EabEntry eab;

Bool b = eab.load(15);
print(b.toString());

eab.setValue("name", "test");
print(eab.getValue("name"));
In This Article
© SuperOffice. All rights reserved.
SuperOffice |  Community |  Release Notes |  Privacy |  Site feedback |  Search Docs |  About Docs |  Contribute |  Back to top