Update ooo320-m1
[ooovba.git] / qadevOOo / tests / java / ifc / text / _XTextGraphicObjectsSupplier.java
blob9edbe1c445bd92b8ba057b1964f073fc85c4cf44
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: _XTextGraphicObjectsSupplier.java,v $
10 * $Revision: 1.4 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 package ifc.text;
33 import lib.MultiMethodTest;
35 import com.sun.star.container.XNameAccess;
36 import com.sun.star.text.XTextGraphicObjectsSupplier;
38 /**
39 * Testing <code>com.sun.star.text.XTextGraphicObjectsSupplier</code>
40 * interface methods :
41 * <ul>
42 * <li><code> getGraphicObjects()</code></li>
43 * </ul> <p>
45 * The component <b>must have</b> the graphic object with
46 * name 'SwXTextDocument'. <p>
48 * Test is <b> NOT </b> multithread compilant. <p>
49 * @see com.sun.star.text.XTextGraphicObjectsSupplier
51 public class _XTextGraphicObjectsSupplier extends MultiMethodTest {
53 public static XTextGraphicObjectsSupplier oObj = null;
55 /**
56 * Gets graphic objects collection from the component, and checks
57 * if the object with name 'SwXTextDocument' exists. <p>
58 * Has <b>OK</b> status if the object exists.
60 public void _getGraphicObjects() {
61 boolean res = false;
63 XNameAccess the_graphics = oObj.getGraphicObjects();
64 res = the_graphics.hasByName("SwXTextDocument");
66 tRes.tested("getGraphicObjects()",res);
69 } // finish class _XTextGraphicObjectsSupplier