Layer.java revision 8845:4be14673b9bf
1157642Sps/* 2265703Sdavidcs * Copyright (c) 2002, 2012, Oracle and/or its affiliates. All rights reserved. 3157642Sps * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4157642Sps * 5157642Sps * This code is free software; you can redistribute it and/or modify it 6157642Sps * under the terms of the GNU General Public License version 2 only, as 7157642Sps * published by the Free Software Foundation. Oracle designates this 8157642Sps * particular file as subject to the "Classpath" exception as provided 9157642Sps * by Oracle in the LICENSE file that accompanied this code. 10157642Sps * 11157642Sps * This code is distributed in the hope that it will be useful, but WITHOUT 12157642Sps * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 13157642Sps * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 14157642Sps * version 2 for more details (a copy is included in the LICENSE file that 15157642Sps * accompanied this code). 16157642Sps * 17157642Sps * You should have received a copy of the GNU General Public License version 18157642Sps * 2 along with this work; if not, write to the Free Software Foundation, 19157642Sps * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 20157642Sps * 21157642Sps * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 22157642Sps * or visit www.oracle.com if you need additional information or have any 23157642Sps * questions. 24157642Sps */ 25157642Sps 26157642Spspackage build.tools.generatenimbus; 27157642Sps 28157642Spsimport java.util.ArrayList; 29157642Spsimport java.util.List; 30265703Sdavidcs 31157642Spsimport javax.xml.bind.annotation.XmlElement; 32157642Spsimport javax.xml.bind.annotation.XmlElementWrapper; 33218529Sdavidchimport javax.xml.bind.annotation.XmlElements; 34218529Sdavidch 35157642Spsclass Layer { 36157642Sps /** List of shapes in this layer, first shape is painted on top */ 37218529Sdavidch @XmlElements({ 38218529Sdavidch @XmlElement(name = "ellipse", type = Ellipse.class), 39218529Sdavidch @XmlElement(name = "path", type = Path.class), 40218529Sdavidch @XmlElement(name = "rectangle", type = Rectangle.class) 41218529Sdavidch }) 42218529Sdavidch @XmlElementWrapper(name="shapes") 43218529Sdavidch private List<Shape> shapes = new ArrayList<Shape>(); 44218529Sdavidch public List<Shape> getShapes() { return shapes; } 45218529Sdavidch 46218529Sdavidch public boolean isEmpty() { 47218529Sdavidch return shapes.isEmpty(); 48218529Sdavidch } 49218529Sdavidch} 50218529Sdavidch