CC ... -lsysadm -lvtcl -ltclx -ltcl -lsocket -lgen -lm#include <scoadmin/basicIncl.h> #include <scoadmin/callBack.h> #include <scoadmin/statusLst.h> #include <scoadmin/CAPI.h>
void FWSetAccessControl(bmipSubmission_cl *bmipSubmissionPtr, accessControl_pt accessControl); void FWUnSetAccessControl(bmipSubmission_cl *bmipSubmissionPtr);
void FWSetSync(bmipSubmission_cl *bmipSubmissionPtr, syncParameter_pt sync);
void FWUnSetSync(bmipSubmission_cl *bmipSubmissionPtr);
void FWSetScope(bmipSubmission_cl *bmipSubmissionPtr, scopeParameter_pt scope);
void FWUnSetScope(bmipSubmission_cl *bmipSubmissionPtr);
void FWSetFilter(bmipSubmission_cl *bmipSubmissionPtr, filterParameter_pt filter);
void FWUnSetFilter(bmipSubmission_cl *bmipSubmissionPtr);
Before calling any of these functions, applications must first call FWInitObjectSubmission 3sadm and obtain a bmipSubmissionPtr for the appropriate object class.
Parameters can be cleared by calling the FWUnSet co-functions.
expression := { expression or expression } := { expression and expression } := { not expression } := { present expression } := { attribute filterOperation value }The filter operations used in a filter expression must be valid for the attribute on which they are used. This is determined individually on a per class basis.filterOperation := eq /* equal to */ := le /* less than or equal to */ := ge /* greater than or equal to */ := subset := superset := intersect
/* Obtain information about all CD-ROM devices on the system */#include <scoadmin/basicIncl.h> #include <scoadmin/callBack.h> #include <scoadmin/statusLst.h> #include <scoadmin/CAPI.h>
main() { frameWorkCClientData_cl *clientDataPtr; bmipSubmission_cl *bmipSubmissionPtr1, *bmipSubmissionPtr2;
scopeParameter_pt scope ="1"; filterParameter_pt filter="type eq cdrom";
/* Initialize general SCOadmin data structure */ clientDataPtr=FWInitializeFrameWork();
/* Initialize class-specific SCOadmin data structures */
/* Initialize communications to the "sco devices" class. */ bmipSubmissionPtr1=FWInitObjectSubmission(clientDataPtr, "sco devices");
/* Identify this as a scoped request */ FWSetScope(bmipSubmissionPtr, scope);
/* Filter against the "type" attribute. Search only for type "cdrom". */ FWSetFilter(bmipSubmissionPtr, filter);
/* Actual object calls go here ... */ ...
/* Unset filter paramters */ FWUnSetScope(bmipSubmissionPtr); FWUnSetFilter(bmipSubmissionPtr);
/* Cleanup */ FWShutdownObjectSubmission(bmipSubmissionPtr1); FWShutdownObjectSubmission(bmipSubmissionPtr2); FWShutdownFrameWork(clientDataPtr); }