ARSperl Programmer's Manual - OO Layer Connection Object

Methods

constructor
  $c = new ARS(-server   => scalar, 
               -username => scalar,
	       -password => scalar,
	       -catch    => hash reference,
               -ctrl     => control record reference,
               -debug    => true or false) 
destructor
If the constructor called ars_Login() itself, then the destructor will call ars_Logoff(). If, however, you are "sharing" a control structer and called ars_Login() yourself (and then passed the control structer into the ARS constructor via the -ctrl parameter) then the destructor will not call ars_Logoff(). Since you called ars_Login(), the OO layer assumes that you will call ars_Logoff() at the appropriate time.

ctrl()
This method returns the control structure. This allows you to call API functions that are not available in the OO layer. For example,
   $c = new ARS(-server => ...);
   ars_Import($c->ctrl(), ...);
By using this, you still have the full power of ARSperl available to you, even when using the OO layer to develop new scripts.

print()
   $c->print();
This method prints out the connection object in a readable format.

availableSchemas()
   @s = $c->availableSchemas(-changedsince => scalar timestamp,
                             -schematype   => scalar,
                             -name         => scalar string);
This method returns a list of available schemas that the current user connection has access to. It is more or less the same as the ars_GetListSchema() call.

The schematype parameter is one of: A
ValueMeaning
ARS::AR_LIST_SCHEMA_ALLget list of all schemas
ARS::AR_LIST_SCHEMA_REGULAR get list of all regular schemas
ARS::AR_LIST_SCHEMA_JOIN get list of all join schemas
ARS::AR_LIST_SCHEMA_VIEW get list of all view schemas
ARS::AR_LIST_SCHEMA_UPLINK get list of all schemas depending
ARS::AR_LIST_SCHEMA_DOWNLINK get list of all schemas the given
ARS::AR_LIST_SCHEMA_DIALOG get list of all dialog schemas
ARS::AR_LIST_SCHEMA_ALL_WITH_DATA get list of all schemas with data
In addition, you may optionally OR (logical OR) the value ARS::AR_HIDDEN_INCREMENT with the above to include hidden schemas in the final list of available schemas.

openForm()
  $f = $c->openForm(-form => scalar string,
                    -vui  => scalar string);
This call opens up a new form and caches some information for you to improve performance. The vui parameter currently does nothing, but it will eventually alter the field labels that you can pass into form->get() form->set(), etc. The form parameter is the name of the form you wish to open (e.g. "User"). Upon successful completetion this call returns a new ARS::form object.

Back to Table of Contents Last updated 12 Mar 1999 by jcmurphy@buffalo.edu.