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 ifc.awt; 25 26 import lib.MultiMethodTest; 27 import lib.Status; 28 29 import com.sun.star.awt.XControl; 30 import com.sun.star.awt.XControlContainer; 31 import com.sun.star.awt.XTabController; 32 import com.sun.star.awt.XTabControllerModel; 33 34 /** 35 * This interface is DEPRECATED !!! 36 * All test results are SKIPPED.OK now. 37 * Testing <code>com.sun.star.awt.XTabController</code> 38 * interface methods : 39 * <ul> 40 * <li><code> activateFirst()</code></li> 41 * <li><code> activateLast()</code></li> 42 * <li><code> activateTabOrder()</code></li> 43 * <li><code> autoTabOrder()</code></li> 44 * <li><code> getContainer()</code></li> 45 * <li><code> getCotrols()</code></li> 46 * <li><code> getModel()</code></li> 47 * <li><code> setContainer()</code></li> 48 * <li><code> setModel()</code></li> 49 * </ul><p> 50 * This test needs the following object relations : 51 * <ul> 52 * <li> <code>'MODEL'</code> : <code>XTabControllerModel</code> a model for 53 * the object</li> 54 * <li> <code>'CONTAINER'</code> : <code>XControlContainer</code> a container 55 * for the object</li> 56 * <ul> <p> 57 * @see com.sun.star.awt.XTabController 58 */ 59 public class _XTabController extends MultiMethodTest { 60 public XTabController oObj = null; 61 62 /** 63 * Test calls the method with object relation 'MODEL' as a parameter.<p> 64 * Has <b> OK </b> status if the method successfully returns 65 * and no exceptions were thrown. <p> 66 */ _setModel()67 public void _setModel() { 68 oObj.setModel( (XTabControllerModel) tEnv.getObjRelation("MODEL")); 69 tRes.tested("setModel()", Status.skipped(true) ); 70 } 71 72 /** 73 * Test calls the method, then checks returned value.<p> 74 * Has <b> OK </b> status if method returns a value that equals to 75 * corresponding object relation.<p> 76 * The following method tests are to be completed successfully before : 77 * <ul> 78 * <li> <code> setModel() </code> : sets model for the object </li> 79 * </ul> 80 */ _getModel()81 public void _getModel() { 82 requiredMethod("setModel()"); 83 XTabControllerModel setModel = oObj.getModel(); 84 tRes.tested("getModel()", Status.skipped(true)); 85 } 86 87 /** 88 * Test calls the method with object relation 'CONTAINER' as a parameter.<p> 89 * Has <b> OK </b> status if the method successfully returns 90 * and no exceptions were thrown. <p> 91 */ _setContainer()92 public void _setContainer() { 93 oObj.setContainer( (XControlContainer) 94 tEnv.getObjRelation("CONTAINER")); 95 tRes.tested("setContainer()", Status.skipped(true)); 96 } 97 98 /** 99 * Test calls the method, then checks returned value.<p> 100 * Has <b> OK </b> status if method returns a value that equals to 101 * corresponding object relation.<p> 102 * The following method tests are to be completed successfully before : 103 * <ul> 104 * <li> <code> setContainer() </code> : sets container for the object</li> 105 * </ul> 106 */ _getContainer()107 public void _getContainer() { 108 requiredMethod( "setContainer()"); 109 XControlContainer setContainer = oObj.getContainer(); 110 XControlContainer relContainer = (XControlContainer ) 111 tEnv.getObjRelation("CONTAINER"); 112 tRes.tested("getContainer()", Status.skipped(true) ); 113 } 114 115 /** 116 * Test calls the method, then checks returned sequence.<p> 117 * Has <b> OK </b> status if returned sequence is not null.<p> 118 */ _getControls()119 public void _getControls() { 120 XControl[] aControl = oObj.getControls(); 121 tRes.tested("getControls()", Status.skipped(true) ); 122 } 123 124 /** 125 * Test calls the method. <p> 126 * Has <b> OK </b> status if the method successfully returns 127 * and no exceptions were thrown. <p> 128 */ _autoTabOrder()129 public void _autoTabOrder() { 130 oObj.autoTabOrder(); 131 tRes.tested("autoTabOrder()", Status.skipped(true)); 132 } 133 134 /** 135 * Test calls the method. <p> 136 * Has <b> OK </b> status if the method successfully returns 137 * and no exceptions were thrown. <p> 138 */ _activateTabOrder()139 public void _activateTabOrder() { 140 oObj.activateTabOrder(); 141 tRes.tested("activateTabOrder()", Status.skipped(true)); 142 } 143 144 /** 145 * Test calls the method. <p> 146 * Has <b> OK </b> status if the method successfully returns 147 * and no exceptions were thrown. <p> 148 */ _activateFirst()149 public void _activateFirst() { 150 oObj.activateFirst(); 151 tRes.tested("activateFirst()", Status.skipped(true)); 152 } 153 154 /** 155 * Test calls the method. <p> 156 * Has <b> OK </b> status if the method successfully returns 157 * and no exceptions were thrown. <p> 158 */ _activateLast()159 public void _activateLast() { 160 oObj.activateLast(); 161 tRes.tested("activateLast()", Status.skipped(true)); 162 } 163 } 164 165