Beispiel #1
0
 /**
  * Returns the CIM method specified by its name and optionally, its origin class. The origin class
  * is the class in which the method is defined.
  *
  * @param pName The string name of the method to get.
  * @param pOriginClass (Optional) The class in which the method was defined.
  * @return The CIM method specified or <code>null</code> if the method does not exist.
  */
 public CIMMethod<?> getMethod(String pName, String pOriginClass) {
   CIMMethod<?> method = (CIMMethod<?>) CIMElementSorter.find(this.iMethods, pName);
   if (method == null) return null;
   if (pOriginClass == null || pOriginClass.equalsIgnoreCase(method.getOriginClass()))
     return method;
   return null;
 }
Beispiel #2
0
 /**
  * Gets the specified property.
  *
  * @param pName The string name of the property to get.
  * @param pOriginClass (Optional) The string name of the class in which the property was defined.
  * @return The property requested or <code>null</code> if the property does not exist.
  */
 public CIMClassProperty<?> getProperty(String pName, String pOriginClass) {
   CIMClassProperty<?> prop = (CIMClassProperty<?>) CIMElementSorter.find(this.iProps, pName);
   if (prop == null || pOriginClass == null) return prop;
   return pOriginClass.equalsIgnoreCase(prop.getOriginClass()) ? prop : null;
 }
Beispiel #3
0
 /**
  * Gets the specified property.
  *
  * @param pName The text string for the name of the property.
  * @return The property requested or <code>null</code> if the property does not exist.
  */
 public CIMClassProperty<?> getProperty(String pName) {
   return (CIMClassProperty<?>) CIMElementSorter.find(this.iProps, pName);
 }