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

  1 karl  1.11 //%2006////////////////////////////////////////////////////////////////////////
  2 w.white 1.1  //
  3              // Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development
  4              // Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems.
  5              // Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L.P.;
  6              // IBM Corp.; EMC Corporation, The Open Group.
  7              // Copyright (c) 2004 BMC Software; Hewlett-Packard Development Company, L.P.;
  8              // IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group.
  9 karl    1.2  // Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.;
 10              // EMC Corporation; VERITAS Software Corporation; The Open Group.
 11 karl    1.11 // Copyright (c) 2006 Hewlett-Packard Development Company, L.P.; IBM Corp.;
 12              // EMC Corporation; Symantec Corporation; The Open Group.
 13 w.white 1.1  //
 14              // Permission is hereby granted, free of charge, to any person obtaining a copy
 15              // of this software and associated documentation files (the "Software"), to
 16              // deal in the Software without restriction, including without limitation the
 17              // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
 18              // sell copies of the Software, and to permit persons to whom the Software is
 19              // furnished to do so, subject to the following conditions:
 20 karl    1.11 // 
 21 w.white 1.1  // THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
 22              // ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
 23              // "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
 24              // LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
 25              // PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
 26              // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
 27              // ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 28              // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 29 karl    1.11 //
 30 w.white 1.1  //==============================================================================
 31              //
 32 w.white 1.3  // Author: Willis White (whiwill@us.ibm.com)
 33 w.white 1.1  //
 34 david.dillard 1.4  // Modified By: David Dillard, VERITAS Software Corp.
 35                    //                  (david.dillard@veritas.com)
 36 aruran.ms     1.9  //              Aruran, IBM(ashanmug@in.ibm.com) for Bug# 3674
 37 w.white       1.1  //
 38                    //%/////////////////////////////////////////////////////////////////////////////
 39                    
 40                    #ifndef ClientPerfDataStore_h
 41                    #define ClientPerfDataStore_h
 42                    
 43                    #include <Pegasus/Common/CIMOperationType.h>
 44                    #include <Pegasus/Common/String.h>
 45 w.white       1.7  #include <Pegasus/Common/TimeValue.h>
 46 w.white       1.1  #include <Pegasus/Client/Linkage.h>
 47 w.white       1.3  #include <Pegasus/Client/ClientOpPerformanceDataHandler.h>
 48 w.white       1.1  
 49                    
 50 w.white       1.3  
 51 david.dillard 1.4  PEGASUS_NAMESPACE_BEGIN
 52                    
 53 w.white       1.3  
 54                    
 55 w.white       1.5  class ClientOpPerformanceDataHandler;
 56 w.white       1.3  struct ClientOpPerformanceData;
 57                    
 58                    /* The ClientPerfDataStore class is internal to pegasus. It has no API's that client apps can
 59                    access. It's purpose is to collect and calculate the data that is returned to the client app
 60                    in the ClientOpPerformanceData object.
 61 david.dillard 1.4  */
 62                    
 63                    class PEGASUS_CLIENT_LINKAGE ClientPerfDataStore
 64 w.white       1.1  
 65                    {
 66                    public:
 67                    
 68 a.dunfey      1.10     ClientPerfDataStore();
 69 w.white       1.1  
 70                        /**Resets all the data members to 0
 71                        */
 72                        void reset();
 73 david.dillard 1.4  
 74 w.white       1.1      /**Creates a ClientOpPerformanceData from the current values of of the private data members
 75                        */
 76 w.white       1.3      ClientOpPerformanceData createPerfDataStruct();
 77 w.white       1.1  
 78 david.dillard 1.4      /**checks the currentMessageID and _operationType data members against
 79 david.dillard 1.8      @param messageID and @param type if the values are equal
 80 w.white       1.1      true is returned.
 81                        @param messageID
 82 w.white       1.3      @param type CIM message type of current message
 83 w.white       1.1      @return true if @param messageID equals currentMessageID data member
 84                        */
 85 aruran.ms     1.9      Boolean checkMessageIDandType(const String& messageID, Uint32 type);
 86 w.white       1.1  
 87                        /**sets the server time data member
 88                        */
 89 w.white       1.7      void setServerTime(Uint32 time);
 90 w.white       1.1  
 91 david.dillard 1.4      /**sets the responsSize data member
 92 w.white       1.1      */
 93 w.white       1.3      void setResponseSize(Uint64 size);
 94 w.white       1.1  
 95 w.white       1.3      /**sets the _requestSize data member
 96 w.white       1.1      */
 97 w.white       1.3      void setRequestSize(Uint64 size);
 98 w.white       1.1  
 99                        /**sets startNetworkTime data member
100                        */
101                        void setStartNetworkTime(void);
102                    
103                        /**sets endNetworkTime data member
104                        */
105 w.white       1.7      void setEndNetworkTime(TimeValue time);
106 w.white       1.1  
107                    
108                        /** sets validServerTime data member
109                        */
110 w.white       1.3      void setServerTimeKnown(Boolean bol);
111 w.white       1.1  
112 david.dillard 1.4      /**sets _operationType data member by translating message type given by
113 w.white       1.3      @param type, into a CIMOperationType. That value is ues to set the _operationType
114 w.white       1.1      data member and is returned.
115                        @param type integer repesenting the message type
116                        */
117 w.white       1.3      void setOperationType(Uint32 type);
118 w.white       1.1  
119                        //void setErrorCondition(Boolean bol);
120                    
121                    
122 w.white       1.6      String toString() const;
123 w.white       1.1  
124                        void setMessageID(String messageID);
125                    
126 w.white       1.6      Boolean getStatError() const;
127 w.white       1.3  
128                        void setClassRegistered(Boolean bol);
129                    
130                        static ClientPerfDataStore *current_Store;
131                    
132                        ClientOpPerformanceDataHandler * handler_prt;
133                    
134 w.white       1.6      Boolean isClassRegistered() const;
135 w.white       1.3  
136                    
137                    protected:
138                        CIMOperationType _operationType;
139                        Boolean _serverTimeKnown;
140                        Boolean _errorCondition;
141                        Boolean _classRegistered;
142                        Uint64 _serverTime;
143 david.dillard 1.4      Uint64 _requestSize;
144                        Uint64 _responseSize;
145 w.white       1.3      String _messID;
146 w.white       1.7      TimeValue _networkEndTime;
147                        TimeValue _networkStartTime;
148 david.dillard 1.4  
149 a.dunfey      1.10 private:
150                        // Make copy-constructor and assignment operator private
151                        ClientPerfDataStore(const ClientPerfDataStore & dataStore);
152                        ClientPerfDataStore& operator=(const ClientPerfDataStore& dataStore);
153 david.dillard 1.4  };
154                    
155 w.white       1.1  
156                    PEGASUS_NAMESPACE_END
157                    
158                    #endif /* ClientPerfDataStore_h */
159                    

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2