Every resource has a set of unique characteristics. Each characteristic has a name, type and value, and the name of each is defined by a constant in the administration message. The name of the resource is a characteristic that is common to all managed resources. The name of the resource is held in the Admin_Name, and it has a type of ASCII.
The full set of characteristics of a resource can be determined by using the characteristics() method against an instance of an administration message. This method returns an MQeFields object that contains one field for each characteristic. MQeFields methods can be used for enumerating over the set of characteristics to obtain the name, type and default value of each characteristic.
The action requested determines the set of characteristics that can be passed to the action. In all cases, at least the name of the resource, Admin_Name, must be passed. In the case of Action_InquireAll this is the only parameter that is required.
SetResourceName( MQeAdminMsg msg, String name ) { MQeFields parms; if ( msg.contains( Admin_Parms ) ) parms = msg.getFields( Admin_Parms ); else parms = new MQeFields(); parms.putAscii( Admin_Name, name ); msg.putFields( Admin_Parms, parms ); }
SetResourceName( MQeAdminMsg msg, String name ) { msg.SetName( name ); }