View Javadoc
1   /*
2     CIMRequest.java
3   
4     (C) Copyright IBM Corp. 2005, 2009
5   
6     THIS FILE IS PROVIDED UNDER THE TERMS OF THE ECLIPSE PUBLIC LICENSE
7     ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THIS FILE
8     CONSTITUTES RECIPIENTS ACCEPTANCE OF THE AGREEMENT.
9   
10    You can obtain a current copy of the Eclipse Public License from
11    http://www.opensource.org/licenses/eclipse-1.0.php
12  
13    @author : Roberto Pineiro, IBM, roberto.pineiro@us.ibm.com
14   * @author : Chung-hao Tan, IBM, chungtan@us.ibm.com
15   * 
16   * 
17   * Change History
18   * Flag       Date        Prog         Description
19   *------------------------------------------------------------------------------- 
20   * 1535756    2006-08-07  lupusalex    Make code warning free
21   * 2003590    2008-06-30  blaschke-oss Change licensing from CPL to EPL
22   * 2524131    2009-01-21  raman_arora  Upgrade client to JDK 1.5 (Phase 1)
23   * 2531371    2009-02-10  raman_arora  Upgrade client to JDK 1.5 (Phase 2) 
24   */
25  
26  package org.metricshub.wbem.sblim.cimclient.internal.cimxml;
27  
28  /*-
29   * ╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲
30   * WBEM Java Client
31   * ჻჻჻჻჻჻
32   * Copyright 2023 - 2025 MetricsHub
33   * ჻჻჻჻჻჻
34   * Licensed under the Apache License, Version 2.0 (the "License");
35   * you may not use this file except in compliance with the License.
36   * You may obtain a copy of the License at
37   *
38   *      http://www.apache.org/licenses/LICENSE-2.0
39   *
40   * Unless required by applicable law or agreed to in writing, software
41   * distributed under the License is distributed on an "AS IS" BASIS,
42   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
43   * See the License for the specific language governing permissions and
44   * limitations under the License.
45   * ╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱╲╱
46   */
47  
48  import java.util.Vector;
49  import org.metricshub.wbem.javax.cim.CIMObjectPath;
50  
51  /**
52   * Class CIMRequest is used by the CIM-XML DOM parser.
53   *
54   */
55  public class CIMRequest extends CIMMessage {
56  	protected Vector<CIMRequest> iRequests = new Vector<CIMRequest>(0);
57  
58  	protected Vector<Object> iParamValue = new Vector<Object>(0);
59  
60  	protected String iMethodName;
61  
62  	protected CIMObjectPath iPath;
63  
64  	protected String iNamespace;
65  
66  	/**
67  	 * Ctor.
68  	 */
69  	public CIMRequest() {
70  		/**/
71  	}
72  
73  	/**
74  	 * Ctor.
75  	 *
76  	 * @param pCimVersion
77  	 * @param pDtdVersion
78  	 * @param pId
79  	 * @param pMethod
80  	 */
81  	public CIMRequest(String pCimVersion, String pDtdVersion, String pId, String pMethod) {
82  		super(pCimVersion, pDtdVersion, pId, pMethod);
83  	}
84  
85  	/**
86  	 * addParamValue
87  	 *
88  	 * @param v
89  	 */
90  	public void addParamValue(Object v) {
91  		if (v instanceof Vector) this.iParamValue.addAll((Vector<?>) v); else this.iParamValue.add(v);
92  	}
93  
94  	/**
95  	 * addRequest
96  	 *
97  	 * @param request
98  	 */
99  	public void addRequest(CIMRequest request) {
100 		this.iRequests.add(request);
101 	}
102 
103 	/**
104 	 * getMethodName
105 	 *
106 	 * @return String
107 	 */
108 	public String getMethodName() {
109 		return this.iMethodName;
110 	}
111 
112 	/**
113 	 * getNameSpace
114 	 *
115 	 * @return String
116 	 */
117 	public String getNameSpace() {
118 		return this.iNamespace;
119 	}
120 
121 	/**
122 	 * getObjectPath
123 	 *
124 	 * @return String
125 	 */
126 	public CIMObjectPath getObjectPath() {
127 		return this.iPath;
128 	}
129 
130 	/**
131 	 * getParamValue
132 	 *
133 	 * @return String
134 	 */
135 	public Vector<Object> getParamValue() {
136 		return this.iParamValue;
137 	}
138 
139 	/**
140 	 * setMethodName
141 	 *
142 	 * @param methodName
143 	 */
144 	public void setMethodName(String methodName) {
145 		this.iMethodName = methodName;
146 	}
147 
148 	/**
149 	 * setNameSpace
150 	 *
151 	 * @param namespace
152 	 */
153 	public void setNameSpace(String namespace) {
154 		this.iNamespace = namespace;
155 	}
156 
157 	/**
158 	 * setObjectPath
159 	 *
160 	 * @param path
161 	 */
162 	public void setObjectPath(CIMObjectPath path) {
163 		this.iPath = path;
164 	}
165 }