1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 
24 package mod._forms;
25 
26 import java.io.PrintWriter;
27 import lib.TestEnvironment;
28 import lib.TestParameters;
29 
30 /**
31  * Test for object which is represented by service
32  * <code>com.sun.star.com.sun.star.form.component.CommandButton</code>.
33  * <p>
34  * Object implements the following interfaces :
35  * <ul>
36  *  <li> <code>com::sun::star::io::XPersistObject</code></li>
37  *  <li> <code>com::sun::star::container::XChild</code></li>
38  *  <li> <code>com::sun::star::form::FormControlModel</code></li>
39  *  <li> <code>com::sun::star::form::XImageProducerSupplier</code></li>
40  *  <li> <code>com::sun::star::form::FormComponent</code></li>
41  *  <li> <code>com::sun::star::beans::XPropertyAccess</code></li>
42 *  <li> <code>com::sun::star::beans::XPropertyContainer</code></li>
43 *  <li> <code>com::sun::star::beans::XPropertySet</code></li>
44  *  <li> <code>com::sun::star::beans::XFastPropertySet</code></li>
45  *  <li> <code>com::sun::star::beans::XPropertyState</code></li>
46  *  <li> <code>com::sun::star::awt::UnoControlButtonModel</code></li>
47  *  <li> <code>com::sun::star::form::component::CommandButton</code></li>
48  *  <li> <code>com::sun::star::container::XNamed</code></li>
49  *  <li> <code>com::sun::star::beans::XMultiPropertySet</code></li>
50  *  <li> <code>com::sun::star::lang::XComponent</code></li>
51  * </ul>
52  * This object test <b> is NOT </b> designed to be run in several
53  * threads concurently.
54  *
55  * @see com.sun.star.io.XPersistObject
56  * @see com.sun.star.container.XChild
57  * @see com.sun.star.form
58  * @see com.sun.star.form.XImageProducerSupplier
59  * @see com.sun.star.form.FormComponent
60  * @see com.sun.star.beans.XPropertyAccess
61 * @see com.sun.star.beans.XPropertyContainer
62 * @see com.sun.star.beans.XPropertySet
63  * @see com.sun.star.beans.XFastPropertySet
64  * @see com.sun.star.beans.XPropertyState
65  * @see com.sun.star.awt.UnoControlButtonModel
66  * @see com.sun.star.form.component.CommandButton
67  * @see com.sun.star.container.XNamed
68  * @see com.sun.star.beans.XMultiPropertySet
69  * @see com.sun.star.lang.XComponent
70  * @see ifc.io._XPersistObject
71  * @see ifc.container._XChild
72  * @see ifc.form._FormControlModel
73  * @see ifc.form._XImageProducerSupplier
74  * @see ifc.form._FormComponent
75  * @see ifc.beans._XPropertySet
76  * @see ifc.beans._XFastPropertySet
77  * @see ifc.beans._XPropertyState
78  * @see ifc.awt._UnoControlButtonModel
79  * @see ifc.form.component._CommandButton
80  * @see ifc.container._XNamed
81  * @see ifc.beans._XMultiPropertySet
82  * @see ifc.lang._XComponent
83  */
84 public class OButtonModel extends GenericModelTest {
85 
86     /**
87      * Set some member variable of the super class <CODE>GenericModelTest</CODE>:
88      * <pre>
89      *    super.m_kindOfControl="CommandButton";
90      *    super.m_ObjectName = "com.sun.star.form.component.CommandButton";
91      *    super.m_LCShape_Type = "CommandButton";
92      * </pre>
93      * Then <CODE>super.initialize()</CODE> was called.
94      * @param tParam the test parameter
95      * @param log the log writer
96      */
97 
initialize(TestParameters tParam, PrintWriter log)98     protected void initialize(TestParameters tParam, PrintWriter log) {
99 
100         super.initialize(tParam, log);
101 
102         super.m_kindOfControl="CommandButton";
103 
104         super.m_ObjectName = "stardiv.one.form.component.CommandButton";
105 
106         super.m_LCShape_Type = "CommandButton";
107 
108     }
109     /**
110      * calls <CODE>cleanup()</CODE> from it's super class
111      * @param tParam the test parameter
112      * @param log the log writer
113      */
cleanup(TestParameters tParam, PrintWriter log)114     protected void cleanup(TestParameters tParam, PrintWriter log) {
115         super.cleanup(tParam, log);
116     }
117 
118 
119     /**
120      * calls <CODE>createTestEnvironment()</CODE> from it's super class
121      * @param Param the test parameter
122      * @param log the log writer
123      * @return lib.TestEnvironment
124      */
createTestEnvironment(TestParameters Param, PrintWriter log)125     protected synchronized TestEnvironment createTestEnvironment(TestParameters Param,
126             PrintWriter log) {
127         return super.createTestEnvironment(Param, log);
128     }
129 
130 }    // finish class OButtonModelold
131