(file) Return to CIMMethod.h CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / Common

Diff for /pegasus/src/Pegasus/Common/CIMMethod.h between version 1.39 and 1.40

version 1.39, 2003/11/12 15:27:53 version 1.40, 2003/11/20 14:50:46
Line 52 
Line 52 
     consists of the following entities:     consists of the following entities:
     <ul>     <ul>
         <li>Name of the method, a CIMName. Functions are provided to manipulate the name.         <li>Name of the method, a CIMName. Functions are provided to manipulate the name.
         The name must be a legal name for a CIMProperty or Method {@link CIMName}.          The name must be a legal name for a CIMProperty or Method \Ref{CIMName}.
         <li>CIMType of the return value of the method, a CIMType.          <li>CIM type of the return value of the method, a \Ref{CIMType}. This is any
         <li>Optional CIMQualifiers for the method. A method can contain zero or          of the predefined CIM types (for example: Boolean);
         more CIMQualifiers and functions are provided to manipulate the          <li>Optional qualifiers (see \Ref{CIMQualifier}) for the method.  A method
         list of CIMQualifiers          can contain zero or more CIMQualifiers and functions are provided to
         <li>Optional CIMParameters for the method which are the parameters to be          manipulate the list of CIMQualifiers.
         placed on a CIM Method operation.  A CIMMethod can contain zero or more          <li>Optional parameters (see \Ref{CIMParameter} for the method which are
         CIMParameters and functions are provided in CIMMethod to manipulate the          the parameters to be placed on a CIM Method operation.  A CIMMethod can
         list of CIMParameters.          contain zero or more CIMParameters and functions are provided in CIMMethod
           to manipulate the list of CIMParameters.
     </ul>     </ul>
     In addition, internally, there are the following additional attributes     In addition, internally, there are the following additional attributes
     that are part of a CIMMethod.      that are part of a CIMMethod including:
     <ul>     <ul>
         <li>propagated - attributed defining whether this CIMMethod is          <li><b>propagated</b> - An attribute defining whether this CIMMethod is
         propagated from a superclass.  Note that this is normally set as part of         propagated from a superclass.  Note that this is normally set as part of
         completing the definition of objects (resolving) when they are placed in a         completing the definition of objects (resolving) when they are placed in a
         repository and is NOT automatically set when creating a local object.  It         repository and is NOT automatically set when creating a local object.  It
         is part of the context of the object within the repository.  It can only         is part of the context of the object within the repository.  It can only
         logically be set in context of the superclass of which this CIMMethod is         logically be set in context of the superclass of which this CIMMethod is
         defined.         defined.
         <li>ClassOrigin - attribute defining the superclass in which this          <li><b>ClassOrigin</b> - An attribute defining the superclass in which this
         CIMMethod was originally defined.  This is normally set as part of         CIMMethod was originally defined.  This is normally set as part of
         resolving Class and instances in the context of other objects (i.e.  a          resolving Class and instances in the context of other objects (for example,  a
         repository).  This attribute is available from objects retrieved from the         repository).  This attribute is available from objects retrieved from the
         repository, for example and indicates the Class/Instance in the hiearchy         repository, for example and indicates the Class/Instance in the hiearchy
         (this object or a superclass or instance of a superclass)was originally         (this object or a superclass or instance of a superclass)was originally
Line 126 
Line 127 
  
     /** Creates a CIMMethod object with the specified name and other input parameters.     /** Creates a CIMMethod object with the specified name and other input parameters.
         @param name CIMName defining the name for the method.         @param name CIMName defining the name for the method.
         @param type CIMType defining data type of method to create. See  
           @param type CIMType defining data type of the method to be created.
  
         @param classOrigin (optional) CIMName representing the class origin. Note         @param classOrigin (optional) CIMName representing the class origin. Note
             that this should normally not be used.  If not provided set to             that this should normally not be used.  If not provided set to
Line 135 
Line 137 
             CIM Method is local to the CIM Class (respectively, Instance) in which             CIM Method is local to the CIM Class (respectively, Instance) in which
             it appears, or was propagated without modification from the a             it appears, or was propagated without modification from the a
             Superclass. Default is false.             Superclass. Default is false.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);
         </pre>         </pre>
Line 146 
Line 149 
         Boolean propagated = false);         Boolean propagated = false);
  
     /** Destructor for the CIMMethod. Since this is a shared class, the destructor     /** Destructor for the CIMMethod. Since this is a shared class, the destructor
         is only releases when there are no more objects pointing to the representation of this          only releases when there are no more objects pointing to the representation
         object.          of this object.
     */     */
     ~CIMMethod();     ~CIMMethod();
  
     /** Assignment operator. Assigns one CIM method to another.  This method performs      /** The assignment operator assigns one CIM method to another.  This method performs
         the assignment by incrementing the reference count for the representation of         the assignment by incrementing the reference count for the representation of
         the CIMMethod, not by creating a deep copy of the object.         the CIMMethod, not by creating a deep copy of the object.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);
             CIMMethod m2 = m1;             CIMMethod m2 = m1;
Line 163 
Line 167 
  
     /** Gets the name of the method.     /** Gets the name of the method.
         @return CIMName with the name of the method.         @return CIMName with the name of the method.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);
             assert(m1.getName() == CIMName ("getHostName"));             assert(m1.getName() == CIMName ("getHostName"));
Line 173 
Line 178 
     /** Sets the method name.     /** Sets the method name.
         @param name - CIMName for the method name. Replaces any         @param name - CIMName for the method name. Replaces any
             previously defined name for this method object.             previously defined name for this method object.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMMethod m2(CIMName ("test"), CIMTYPE_STRING);             CIMMethod m2(CIMName ("test"), CIMTYPE_STRING);
             m2.setName(CIMName ("getVersion"));             m2.setName(CIMName ("getVersion"));
Line 183 
Line 189 
     /** Gets the method type.     /** Gets the method type.
         @return The CIMType containing the method type for this method.         @return The CIMType containing the method type for this method.
         This is the type returned as the return value of a method operation.         This is the type returned as the return value of a method operation.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);
             assert(m1.getType() == CIMTYPE_STRING);             assert(m1.getType() == CIMTYPE_STRING);
Line 194 
Line 201 
         as defined in CIMType. This is the type of the CIMValue         as defined in CIMType. This is the type of the CIMValue
         that is returned on a CIMMethod operation         that is returned on a CIMMethod operation
         @param type CIMType to be set into the method object.         @param type CIMType to be set into the method object.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMMethod m1();             CIMMethod m1();
             m1.setName(CIMName ("getVersion"));             m1.setName(CIMName ("getVersion"));
Line 224 
Line 232 
         classes into the repository (resolving the class).  It is         classes into the repository (resolving the class).  It is
         available on methods in classes read from the repository and         available on methods in classes read from the repository and
         on instances that are read from the instance repository.         on instances that are read from the instance repository.
         @return true if method is propagated, false otherwise.          @return True if method is propagated; otherwise,false.
     */     */
     Boolean getPropagated() const;     Boolean getPropagated() const;
  
     /** Sets the Propagaged Qualifier. Normally this is used by the functions     /** Sets the Propagaged Qualifier. Normally this is used by the functions
         that resolve classes and instances as part of the installation into         that resolve classes and instances as part of the installation into
         a repository.         a repository.
         @param propagated Flag indicating propagation. True means that          @param propagated Flag indicating method is propagated from superclass propagation.
         the method was propagated from a superclass.          True means that the method was propagated from superclass.
     */     */
     void setPropagated(Boolean propagated);     void setPropagated(Boolean propagated);
  
     /** Adds the specified qualifier to the method and increments the     /** Adds the specified qualifier to the method and increments the
         qualifier count.         qualifier count.
         @param x - CIMQualifier object representing the qualifier          @param x CIMQualifier object representing the qualifier
         to be added.         to be added.
         @return the CIMMethod object after adding the specified qualifier.         @return the CIMMethod object after adding the specified qualifier.
         @exception AlreadyExistsException if the qualifier already exists.         @exception AlreadyExistsException if the qualifier already exists.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);
             m1.addQualifier(CIMQualifier(CIMName ("stuff"), true));             m1.addQualifier(CIMQualifier(CIMName ("stuff"), true));
Line 250 
Line 259 
     CIMMethod& addQualifier(const CIMQualifier& x);     CIMMethod& addQualifier(const CIMQualifier& x);
  
     /** Searches for a qualifier with the specified input name.     /** Searches for a qualifier with the specified input name.
         @param name - CIMName of the qualifier to be found.          @param name CIMName of the qualifier to be found.
         @return Index of the qualifier found or PEG_NOT_FOUND         @return Index of the qualifier found or PEG_NOT_FOUND
         if not found.         if not found.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);
             m1.addQualifier(CIMQualifier(CIMName ("stuff"), true));             m1.addQualifier(CIMQualifier(CIMName ("stuff"), true));
Line 262 
Line 272 
     Uint32 findQualifier(const CIMName& name) const;     Uint32 findQualifier(const CIMName& name) const;
  
     /** Gets the CIMQualifier defined by the input parameter.     /** Gets the CIMQualifier defined by the input parameter.
         @param index - Index of the qualifier requested.          @param index Index of the qualifier requested.
         @return CIMQualifier object representing the qualifier found.         @return CIMQualifier object representing the qualifier found.
         @exception IndexOutOfBoundsException exception if the index is         @exception IndexOutOfBoundsException exception if the index is
         outside the range of parameters available from the CIMMethod.         outside the range of parameters available from the CIMMethod.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);
             m1.addQualifier(CIMQualifier(CIMName ("stuff"), true));             m1.addQualifier(CIMQualifier(CIMName ("stuff"), true));
Line 277 
Line 288 
     CIMQualifier getQualifier(Uint32 index);     CIMQualifier getQualifier(Uint32 index);
  
     /** Gets the CIMQualifier defined by the input parameter.     /** Gets the CIMQualifier defined by the input parameter.
         @param index - Index of the qualifier requested.          @param index Index of the qualifier requested.
         @return CIMConstQualifier object representing the qualifier found.         @return CIMConstQualifier object representing the qualifier found.
         @exception IndexOutOfBoundsException exception if the index is         @exception IndexOutOfBoundsException exception if the index is
         outside the range of parameters available from the CIMMethod.         outside the range of parameters available from the CIMMethod.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);
             m1.addQualifier(CIMQualifier(CIMName ("stuff"), true));             m1.addQualifier(CIMQualifier(CIMName ("stuff"), true));
Line 293 
Line 305 
     CIMConstQualifier getQualifier(Uint32 index) const;     CIMConstQualifier getQualifier(Uint32 index) const;
  
     /** Removes the specified CIMQualifier from this method.     /** Removes the specified CIMQualifier from this method.
         @param index - Index of the qualifier to remove.          @param index Index of the qualifier to remove.
         @exception IndexOutOfBoundsException exception if the index is         @exception IndexOutOfBoundsException exception if the index is
             outside the range of parameters available from the CIMMethod.             outside the range of parameters available from the CIMMethod.
     */     */
Line 301 
Line 313 
  
     /** Returns the number of Qualifiers attached to this CIMMethod object.     /** Returns the number of Qualifiers attached to this CIMMethod object.
         @return the number of qualifiers in the CIM Method.         @return the number of qualifiers in the CIM Method.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);
             m1.addQualifier(CIMQualifier(CIMName ("stuff"), true));             m1.addQualifier(CIMQualifier(CIMName ("stuff"), true));
Line 311 
Line 324 
     Uint32 getQualifierCount() const;     Uint32 getQualifierCount() const;
  
     /** Adds the parameter defined by the input to the CIMMethod.     /** Adds the parameter defined by the input to the CIMMethod.
         @param x - CIMParameter to be added to the CIM Method.          @param x CIMParameter to be added to the CIM Method.
         @return CIMMethod object after the specified parameter is added.         @return CIMMethod object after the specified parameter is added.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);
             m1.addParameter(CIMParameter(CIMName ("ipaddress"), CIMTYPE_STRING));             m1.addParameter(CIMParameter(CIMName ("ipaddress"), CIMTYPE_STRING));
Line 321 
Line 335 
     CIMMethod& addParameter(const CIMParameter& x);     CIMMethod& addParameter(const CIMParameter& x);
  
     /** Finds the parameter with the specified name.     /** Finds the parameter with the specified name.
         @param name - Name of parameter to be found.          @param name CIMName of parameter to be found.
         @return Index of the parameter object found or PEG_NOT_FOUND         @return Index of the parameter object found or PEG_NOT_FOUND
         if the property is not found.         if the property is not found.
           <p><b>Example:</b>
         <pre>         <pre>
             Uint32 posParameter;             Uint32 posParameter;
             posParameter = m1.findParameter(CIMName ("ipaddress"));             posParameter = m1.findParameter(CIMName ("ipaddress"));
Line 334 
Line 349 
     Uint32 findParameter(const CIMName& name) const;     Uint32 findParameter(const CIMName& name) const;
  
     /** Gets the parameter defined by the specified index.     /** Gets the parameter defined by the specified index.
         @param index - Index for the parameter to be returned.          @param index Index for the parameter to be returned.
         @return CIMParameter object requested.         @return CIMParameter object requested.
         @exception IndexOutOfBoundsException if the index is outside         @exception IndexOutOfBoundsException if the index is outside
             the range of available parameters.             the range of available parameters.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMParameter cp = m1.getParameter(m1.findParameter(CIMName ("ipaddress")));             CIMParameter cp = m1.getParameter(m1.findParameter(CIMName ("ipaddress")));
         </pre>         </pre>
Line 345 
Line 361 
     CIMParameter getParameter(Uint32 index);     CIMParameter getParameter(Uint32 index);
  
     /** Gets the parameter defined for the specified index.     /** Gets the parameter defined for the specified index.
         @param index - Index for the parameter to be returned.          @param index Index for the parameter to be returned.
         @return CIMConstParameter object requested.         @return CIMConstParameter object requested.
         @exception IndexOutOfBoundsException if the index is outside         @exception IndexOutOfBoundsException if the index is outside
             the range of available parameters             the range of available parameters
Line 353 
Line 369 
     CIMConstParameter getParameter(Uint32 index) const;     CIMConstParameter getParameter(Uint32 index) const;
  
     /** Removes the CIMParameter defined by the specified index.     /** Removes the CIMParameter defined by the specified index.
         @param index - Index of the parameter to be removed.          @param index Index of the parameter to be removed.
         @exception IndexOutOfBoundsException if the index is outside the         @exception IndexOutOfBoundsException if the index is outside the
             range of parameters available from the CIMMethod.             range of parameters available from the CIMMethod.
     */     */
     void removeParameter (Uint32 index);     void removeParameter (Uint32 index);
  
     /** Gets the count of Parameters defined in the CIMMethod.     /** Gets the count of Parameters defined in the CIMMethod.
         @return - count of the number of parameters attached to the CIMMethod.          @return Count of the number of parameters attached to the CIMMethod.
     */     */
     Uint32 getParameterCount() const;     Uint32 getParameterCount() const;
  
     /** Determines if the object has not been initialized.     /** Determines if the object has not been initialized.
         @return  true if the object has not been initialized,          @return  True if the object has not been initialized,
                  false otherwise false.                  false otherwise false.
      */      */
     Boolean isUninitialized() const;     Boolean isUninitialized() const;
  
     /** Compares with another CIMConstMethod.     /** Compares with another CIMConstMethod.
         @param x - CIMConstMethod object for the method to be compared.          @param x CIMConstMethod object for the method to be compared.
         @return true if this method is identical to the one specified.         @return true if this method is identical to the one specified.
           <p><b>Example:</b>
         <pre>         <pre>
             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);             CIMMethod m1(CIMName ("getHostName"), CIMTYPE_STRING);
             CIMMethod m2(CIMName ("test"), CIMTYPE_STRING);             CIMMethod m2(CIMName ("test"), CIMTYPE_STRING);
Line 381 
Line 398 
     */     */
     Boolean identical(const CIMConstMethod& x) const;     Boolean identical(const CIMConstMethod& x) const;
  
     /** Makes a deep copy (clone) of this method.      /** Makes a clone (deep copy) of this method. This creates
           a new copy of all of the components of the method including
           parameters and qualifiers.
         @return copy of the CIMMethod object.         @return copy of the CIMMethod object.
     */     */
     CIMMethod clone() const;     CIMMethod clone() const;
Line 405 
Line 424 
     same manner as the CIMMethod class except that the const attribute     same manner as the CIMMethod class except that the const attribute
     is applied to the objects created. This class includes equivalents     is applied to the objects created. This class includes equivalents
     to the methods from CIMMethod that are usable in a const object including     to the methods from CIMMethod that are usable in a const object including
     constructors, (i.e. getter methods) and the destructor.      constructors, (for example: getter methods) and the destructor.
     The const form of the object is used TBD  
     ATTN: Complete the explanation of why.      REVIEWERS: ATTN: Complete the explanation of why.
 */ */
 class PEGASUS_COMMON_LINKAGE CIMConstMethod class PEGASUS_COMMON_LINKAGE CIMConstMethod
 { {
Line 447 
Line 466 
     prevent unplanned modification of the object     prevent unplanned modification of the object
     @param x CIMMethod object that is to be assigned to another     @param x CIMMethod object that is to be assigned to another
     CIMMethod object.     CIMMethod object.
       <p><b>Example:</b>
     <pre>     <pre>
     CIMMethod cm1("putthing");     CIMMethod cm1("putthing");
     </pre>     </pre>


Legend:
Removed from v.1.39  
changed lines
  Added in v.1.40

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2