You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by ah...@apache.org on 2012/08/08 22:03:36 UTC

[4/5] Removed all javax source code from utils package

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/JoinTable.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/JoinTable.java b/utils/src/javax/persistence/JoinTable.java
deleted file mode 100644
index 888a7ec..0000000
--- a/utils/src/javax/persistence/JoinTable.java
+++ /dev/null
@@ -1,122 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.FIELD;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * This annotation is used in the mapping of associations. It 
- * is specified on the owning side of a many-to-many association, 
- * or in a unidirectional one-to-many association.
- *
- * <p> If the <code>JoinTable</code> annotation is missing, the 
- * default values of the annotation elements apply.  The name 
- * of the join table is assumed to be the table names of the 
- * associated primary tables concatenated together (owning side 
- * first) using an underscore.
- *
- * <pre>
- *
- *    Example:
- *    &#064;JoinTable(
- *    name="CUST_PHONE",
- *    joinColumns=
- *        &#064;JoinColumn(name="CUST_ID", referencedColumnName="ID"),
- *    inverseJoinColumns=
- *        &#064;JoinColumn(name="PHONE_ID", referencedColumnName="ID")
- *    )
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target({METHOD, FIELD}) 
-@Retention(RUNTIME)
-
-public @interface JoinTable {
-
-    /**
-     * (Optional) The name of the join table. 
-     * 
-     * <p> Defaults to the concatenated names of
-     * the two associated primary entity tables, 
-     * separated by an underscore.
-     */
-    String name() default "";
-
-    /** (Optional) The catalog of the table. 
-     * <p> Defaults to the default catalog.
-     */
-    String catalog() default "";
-
-    /** (Optional) The schema of the table. 
-     * <p> Defaults to the default schema for user.
-     */
-    String schema() default "";
-
-    /**
-     * (Optional) The foreign key columns
-     * of the join table which reference the
-     * primary table of the entity owning the
-     * association (i.e. the owning side of
-     * the association).
-     *
-     * <p> Uses the same defaults as for {@link JoinColumn}.
-     */
-    JoinColumn[] joinColumns() default {};
-
-    /** 
-     * (Optional) The foreign key columns
-     * of the join table which reference the
-     * primary table of the entity that does
-     * not own the association (i.e. the
-     * inverse side of the association).
-     *
-     * <p> Uses the same defaults as for {@link JoinColumn}.
-     */
-    JoinColumn[] inverseJoinColumns() default {};
-
-    /**
-     * (Optional) Unique constraints that are
-     * to be placed on the table. These are
-     * only used if table generation is in effect.
-     * <p> Defaults to no additional constraints.
-     */
-    UniqueConstraint[] uniqueConstraints() default {};
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/Lob.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/Lob.java b/utils/src/javax/persistence/Lob.java
deleted file mode 100644
index 7fca155..0000000
--- a/utils/src/javax/persistence/Lob.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.FIELD;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * Specifies that a persistent property or field should be persisted 
- * as a large object to a database-supported large object type. 
- * The <code>Lob</code> annotation may be used in conjunction 
- * with the {@link Basic} annotation. A <code>Lob</code> may be 
- * either a binary or character type. 
- *
- * <p> The <code>Lob</code> type is inferred from the type of the 
- * persistent field or property, and except for string and 
- * character-based types defaults to Blob.
- * <pre>
- *
- *   Example:
- *
- *   &#064;Lob &#064;Basic(fetch=LAZY)
- *   &#064;Column(name="REPORT")
- *   protected String report;
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target({METHOD, FIELD}) 
-@Retention(RUNTIME)
-public @interface Lob {
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/LockModeType.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/LockModeType.java b/utils/src/javax/persistence/LockModeType.java
deleted file mode 100644
index 3b9dd68..0000000
--- a/utils/src/javax/persistence/LockModeType.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-/**
- * Lock modes that can be specified by means of the 
- * {@link EntityManager#lock EntityManager.lock()} method.
- * 
- * <p> The semantics of requesting locks of type 
- * {@link LockModeType#READ LockModeType.READ} and {@link 
- * LockModeType#WRITE LockModeType.WRITE} are the following.
- *
- * <p> If transaction T1 calls lock(entity, {@link 
- * LockModeType#READ LockModeType.READ}) on a versioned object, 
- * the entity manager must ensure that neither of the following 
- * phenomena can occur:
- * <ul>
- *   <li> P1 (Dirty read): Transaction T1 modifies a row. 
- * Another transaction T2 then reads that row and obtains 
- * the modified value, before T1 has committed or rolled back. 
- * Transaction T2 eventually commits successfully; it does not 
- * matter whether T1 commits or rolls back and whether it does 
- * so before or after T2 commits.
- *   <li>
- *   </li> P2 (Non-repeatable read): Transaction T1 reads a row. 
- * Another transaction T2 then modifies or deletes that row, 
- * before T1 has committed. Both transactions eventually commit 
- * successfully.
- *   </li>
- * </ul>
- *
- * <p> Lock modes must always prevent the phenomena P1 and P2.
- *
- * <p> In addition, calling lock(entity, LockModeType.WRITE) on 
- * a versioned object, will also force an update (increment) to 
- * the entity's version column.
- *
- * <p> The persistence implementation is not required to support 
- * calling {@link EntityManager#lock EntityManager.lock()} on a 
- * non-versioned object. When it cannot support a such lock call, 
- * it must throw the {@link PersistenceException}.
- *
- *
- * @since Java Persistence 1.0
- */
-public enum LockModeType  {
-
-    /** Read lock */
-    READ,
-
-    /** Write lock */
-    WRITE
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/ManyToMany.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/ManyToMany.java b/utils/src/javax/persistence/ManyToMany.java
deleted file mode 100644
index 4a681f1..0000000
--- a/utils/src/javax/persistence/ManyToMany.java
+++ /dev/null
@@ -1,146 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import javax.persistence.CascadeType;
-import static java.lang.annotation.ElementType.FIELD;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-import static javax.persistence.FetchType.LAZY;
-
-/**
- * Defines a many-valued association with many-to-many multiplicity. 
- * If the Collection is defined using generics to specify the element 
- * type, the associated target entity class does not need to be 
- * specified; otherwise it must be specified.
- *
- * <p> Every many-to-many association has two sides, the owning 
- * side and the non-owning, or inverse, side.  The join table is 
- * specified on the owning side. If the association is bidirectional, 
- * either side may be designated as the owning side.
- *
- * <p> The same annotation elements for the {@link OneToMany} 
- * annotation apply to the <code>ManyToMany</code> annotation. 
- *
- * <pre>
- *
- *    Example 1:
- *
- *    In Customer class:
- *
- *    &#064;ManyToMany
- *    &#064;JoinTable(name="CUST_PHONES")
- *    public Set<PhoneNumber> getPhones() { return phones; }
- *
- *    In PhoneNumber class:
- *
- *    &#064;ManyToMany(mappedBy="phones")
- *    public Set<Customer> getCustomers() { return customers; }
- *
- *    Example 2:
- *
- *    In Customer class:
- *
- *    &#064;ManyToMany(targetEntity=com.acme.PhoneNumber.class)
- *    public Set getPhones() { return phones; }
- *
- *    In PhoneNumber class:
- *
- *    &#064;ManyToMany(targetEntity=com.acme.Customer.class, mappedBy="phones")
- *    public Set getCustomers() { return customers; }
- *
- *    Example 3:
- *
- *    In Customer class:
- *
- *    &#064;ManyToMany
- *    &#064;JoinTable(name="CUST_PHONE",
- *        joinColumns=
- *            &#064;JoinColumn(name="CUST_ID", referencedColumnName="ID"),
- *        inverseJoinColumns=
- *            &#064;JoinColumn(name="PHONE_ID", referencedColumnName="ID")
- *        )
- *    public Set<PhoneNumber> getPhones() { return phones; }
- *
- *    In PhoneNumberClass:
- *
- *    &#064;ManyToMany(mappedBy="phones")
- *    public Set<Customer> getCustomers() { return customers; }
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target({METHOD, FIELD}) 
-@Retention(RUNTIME)
-
-public @interface ManyToMany {
-
-    /**
-     * (Optional) The entity class that is the target
-     * of the association. Optional only if the collection
-     * property is defined using Java generics.
-     * Must be specified otherwise.
-     *
-     * <p> Defaults to the parameterized type of
-     * the collection when defined using generics.
-     */
-    Class targetEntity() default void.class;
-
-    /** 
-     * (Optional) The operations that must be cascaded to 
-     * the target of the association.
-     * <p> Defaults to no operations being cascaded.
-     */
-    CascadeType[] cascade() default {};
-
-    /** (Optional) Whether the association should be
-     * lazily loaded or must be eagerly fetched. The
-     * {@link FetchType#EAGER EAGER} strategy is a 
-     * requirement on the persistenceprovider runtime 
-     * that the associatedentities must be eagerly fetched. 
-     * The {@link FetchType#LAZY LAZY} strategy is a hint 
-     * to the persistence provider runtime.
-     */
-    FetchType fetch() default LAZY;
-
-    /** 
-     * The field that owns the relationship. Required unless 
-     * the relationship is unidirectional.
-     */
-    String mappedBy() default "";
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/ManyToOne.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/ManyToOne.java b/utils/src/javax/persistence/ManyToOne.java
deleted file mode 100644
index fb5f4fa..0000000
--- a/utils/src/javax/persistence/ManyToOne.java
+++ /dev/null
@@ -1,99 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import javax.persistence.CascadeType;
-import static java.lang.annotation.ElementType.FIELD;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-import static javax.persistence.FetchType.EAGER;
-
-/**
- * This annotation defines a single-valued association to another 
- * entity class that has many-to-one multiplicity. It is not normally 
- * necessary to specify the target entity explicitly since it can 
- * usually be inferred from the type of the object being referenced.
- *
- * <pre>
- *
- *     Example:
- *
- *     &#064;ManyToOne(optional=false) 
- *     &#064;JoinColumn(name="CUST_ID", nullable=false, updatable=false)
- *     public Customer getCustomer() { return customer; }
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target({METHOD, FIELD}) 
-@Retention(RUNTIME)
-
-public @interface ManyToOne {
-
-    /** 
-     * (Optional) The entity class that is the target of 
-     * the association. 
-     *
-     * <p> Defaults to the type of the field or property 
-     * that stores the association. 
-     */
-    Class targetEntity() default void.class;
-
-    /**
-     * (Optional) The operations that must be cascaded to 
-     * the target of the association.
-     *
-     * <p> By default no operations are cascaded.
-     */
-    CascadeType[] cascade() default {};
-
-    /** 
-     * (Optional) Whether the association should be lazily 
-     * loaded or must be eagerly fetched. The {@link FetchType#EAGER EAGER} 
-     * strategy is a requirement on the persistence provider runtime that 
-     * the associated entity must be eagerly fetched. The {@link FetchType#LAZY 
-     * LAZY} strategy is a hint to the persistence provider runtime.
-     */
-    FetchType fetch() default EAGER;
-
-    /** 
-     * (Optional) Whether the association is optional. If set 
-     * to false then a non-null relationship must always exist.
-     */
-    boolean optional() default true;
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/MapKey.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/MapKey.java b/utils/src/javax/persistence/MapKey.java
deleted file mode 100644
index 0977f59..0000000
--- a/utils/src/javax/persistence/MapKey.java
+++ /dev/null
@@ -1,120 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.FIELD;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * Is used to specify the map key for associations of type 
- * {@link java.util.Map}.
- * 
- * <p> If a persistent field or property other than the primary 
- * key is used as a map key then it is expected to have a 
- * uniqueness constraint associated with it.
- *
- * <pre>
- *
- *    Example 1:
- *
- *    &#064;Entity
- *    public class Department {
- *        ...
- *        &#064;OneToMany(mappedBy="department")
- *        &#064;MapKey(name="empId")
- *        public Map<Integer, Employee> getEmployees() {... }
- *        ...
- *    }
- *
- *    &#064;Entity
- *    public class Employee {
- *        ...
- *        &#064;Id Integer getEmpid() { ... }
- *        &#064;ManyToOne
- *        &#064;JoinColumn(name="dept_id")
- *        public Department getDepartment() { ... }
- *        ...
- *    }
- *
- *    Example 2:
- *
- *    &#064;Entity
- *        public class Department {
- *        ...
- *        &#064;OneToMany(mappedBy="department")
- *        &#064;MapKey(name="empPK")
- *        public Map<EmployeePK, Employee> getEmployees() {... }
- *        ...
- *    }
- *
- *    &#064;Entity
- *        public class Employee {
- *        &#064;EmbeddedId public EmployeePK getEmpPK() { ... }
- *        ...
- *        &#064;ManyToOne
- *        &#064;JoinColumn(name="dept_id")
- *        public Department getDepartment() { ... }
- *        ...
- *    }
- *
- *    &#064;Embeddable
- *    public class EmployeePK {
- *        String name;
- *        Date bday;
- *    }
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target({METHOD, FIELD}) 
-@Retention(RUNTIME)
-
-public @interface MapKey {
-
-    /**
-     * The name of the persistent field or property of the 
-     * associated entity that is used as the map key. If the 
-     * name element is not specified, the primary key of the 
-     * associated entity is used as the map key. If the 
-     * primary key is a composite primary key and is mapped 
-     * as {@link IdClass}, an instance of the primary key 
-     * class is used as the key.
-     */
-    String name() default "";
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/MappedSuperclass.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/MappedSuperclass.java b/utils/src/javax/persistence/MappedSuperclass.java
deleted file mode 100644
index 0dda69c..0000000
--- a/utils/src/javax/persistence/MappedSuperclass.java
+++ /dev/null
@@ -1,152 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.TYPE;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * Designates a class whose mapping information is applied 
- * to the entities that inherit from it. A mapped superclass 
- * has no separate table defined for it.  
- *
- * <p> A class designated with the <code>MappedSuperclass</code> 
- * annotation can be mapped in the same way as an entity except that the 
- * mappings will apply only to its subclasses since no table 
- * exists for the mapped superclass itself. When applied to the 
- * subclasses the inherited mappings will apply in the context 
- * of the subclass tables. Mapping information may be overridden 
- * in such subclasses by using the {@link AttributeOverride} and 
- * {@link AssociationOverride} annotations or corresponding XML elements.
- *
- * <pre>
- *    Example: Concrete class as a mapped superclass
- *
- *    &#064;MappedSuperclass
- *    public class Employee {
- *    
- *        &#064;Id protected Integer empId;
- *        &#064;Version protected Integer version;
- *        &#064;ManyToOne &#064;JoinColumn(name="ADDR")
- *        protected Address address;
- *    
- *        public Integer getEmpId() { ... }
- *        public void setEmpId(Integer id) { ... }
- *        public Address getAddress() { ... }
- *        public void setAddress(Address addr) { ... }
- *    }
- *    
- *    // Default table is FTEMPLOYEE table
- *    &#064;Entity
- *    public class FTEmployee extends Employee {
- *    
- *        // Inherited empId field mapped to FTEMPLOYEE.EMPID
- *        // Inherited version field mapped to FTEMPLOYEE.VERSION
- *        // Inherited address field mapped to FTEMPLOYEE.ADDR fk
- *        
- *    
- *    // Defaults to FTEMPLOYEE.SALARY
- *    
- *    protected Integer salary;
- *    
- *    
- *    public FTEmployee() {}
- *    
- *    
- *    public Integer getSalary() { ... }
- *    
- *    public void setSalary(Integer salary) { ... }
- *    }
- *    
- *    &#064;Entity &#064;Table(name="PT_EMP")
- *    &#064;AssociationOverride(name="address", 
- *    
- *    
- *    joincolumns=&#064;JoinColumn(name="ADDR_ID"))
- *    public class PartTimeEmployee extends Employee {
- *    
- *        // Inherited empId field mapped to PT_EMP.EMPID
- *        // Inherited version field mapped to PT_EMP.VERSION
- *        // address field mapping overridden to PT_EMP.ADDR_ID fk
- *        &#064;Column(name="WAGE")
- *        protected Float hourlyWage;
- *    
- *        public PartTimeEmployee() {}
- *    
- *        public Float getHourlyWage() { ... }
- *        public void setHourlyWage(Float wage) { ... }
- *    }
- *
- *    Example: Non-entity superclass
- *
- *    public class Cart {
- *    
- *        // This state is transient
- *        Integer operationCount;
- *    
- *        public Cart() { operationCount = 0; }
- *        public Integer getOperationCount() { return operationCount; }
- *        public void incrementOperationCount() { operationCount++; }
- *    }
- *    
- *    &#064Entity
- *    public class ShoppingCart extends Cart {
- *    
- *        Collection<Item> items = new Vector<Item>();
- *    
- *        public ShoppingCart() { super(); }
- *    
- *    
- *    ...
- *    
- *        &#064OneToMany
- *        public Collection<Item> getItems() { return items; }
- *        public void addItem(Item item) {
- *            items.add(item);
- *            incrementOperationCount();
- *        }
- *    }
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target({TYPE})
-@Retention(RUNTIME)
-
-public @interface MappedSuperclass {
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/OneToMany.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/OneToMany.java b/utils/src/javax/persistence/OneToMany.java
deleted file mode 100644
index 5c2674c..0000000
--- a/utils/src/javax/persistence/OneToMany.java
+++ /dev/null
@@ -1,123 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import javax.persistence.CascadeType;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.ElementType.FIELD;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-import static javax.persistence.FetchType.LAZY;
-
-/**
- * Defines a many-valued association with one-to-many multiplicity.
- * 
- * <p> If the collection is defined using generics to specify the 
- * element type, the associated target entity type need not be 
- * specified; otherwise the target entity class must be specified.
- *
- * <pre>
- *
- *    Example 1: One-to-Many association using generics
- *
- *    In Customer class:
- *
- *    &#064;OneToMany(cascade=ALL, mappedBy="customer")
- *    public Set<Order> getOrders() { return orders; }
- *
- *    In Order class:
- *
- *    &#064;ManyToOne
- *    &#064;JoinColumn(name="CUST_ID", nullable=false)
- *    public Customer getCustomer() { return customer; }
- *
- *    Example 2: One-to-Many association without using generics
- *
- *    In Customer class:
- *
- *    &#064;OneToMany(targetEntity=com.acme.Order.class, cascade=ALL,
- *            mappedBy="customer")
- *    public Set getOrders() { return orders; }
- *
- *    In Order class:
- *
- *    &#064;ManyToOne
- *    &#064;JoinColumn(name="CUST_ID", nullable=false)
- *    public Customer getCustomer() { return customer; }
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target({METHOD, FIELD}) 
-@Retention(RUNTIME)
-
-public @interface OneToMany {
-
-    /**
-     * (Optional) The entity class that is the target
-     * of the association. Optional only if the collection
-     * property is defined using Java generics.
-     * Must be specified otherwise.
-     *
-     * <p> Defaults to the parameterized type of
-     * the collection when defined using generics.
-     */
-    Class targetEntity() default void.class;
-
-    /** 
-     * (Optional) The operations that must be cascaded to 
-     * the target of the association.
-     * <p> Defaults to no operations being cascaded.
-     */
-    CascadeType[] cascade() default {};
-
-    /** (Optional) Whether the association should be
-     * lazily loaded or must be eagerly fetched. The
-     * {@link FetchType#EAGER EAGER} strategy is a 
-     * requirement on the persistenceprovider runtime 
-     * that the associatedentities must be eagerly fetched. 
-     * The {@link FetchType#LAZY LAZY} strategy is a hint 
-     * to the persistence provider runtime.
-     */
-    FetchType fetch() default LAZY;
-
-    /** 
-     * The field that owns the relationship. Required unless 
-     * the relationship is unidirectional.
-     */
-    String mappedBy() default "";
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/OneToOne.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/OneToOne.java b/utils/src/javax/persistence/OneToOne.java
deleted file mode 100644
index 59f1c3f..0000000
--- a/utils/src/javax/persistence/OneToOne.java
+++ /dev/null
@@ -1,134 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import javax.persistence.CascadeType;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.ElementType.FIELD;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-import static javax.persistence.FetchType.EAGER;
-
-/**
- * This annotation defines a single-valued association to 
- * another entity that has one-to-one multiplicity. It is not 
- * normally necessary to specify the associated target entity 
- * explicitly since it can usually be inferred from the type 
- * of the object being referenced.
- *
- * <pre>
- *    Example 1: One-to-one association that maps a foreign key column
- *
- *    On Customer class:
- *
- *    &#064;OneToOne(optional=false)
- *    &#064;JoinColumn(
- *    	name="CUSTREC_ID", unique=true, nullable=false, updatable=false)
- *    public CustomerRecord getCustomerRecord() { return customerRecord; }
- *
- *    On CustomerRecord class:
- *
- *    &#064;OneToOne(optional=false, mappedBy="customerRecord")
- *    public Customer getCustomer() { return customer; }
- *
- *    Example 2: One-to-one association that assumes both the source and target share the same primary key values. 
- *
- *    On Employee class:
- *
- *    &#064;Entity
- *    public class Employee {
- *    	&#064;Id Integer id;
- *    
- *    	&#064;OneToOne &#064;PrimaryKeyJoinColumn
- *    	EmployeeInfo info;
- *    	...
- *    }
- *
- *    On EmployeeInfo class:
- *
- *    &#064;Entity
- *    public class EmployeeInfo {
- *    	&#064;Id Integer id;
- *    	...
- *    }
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target({METHOD, FIELD}) 
-@Retention(RUNTIME)
-
-public @interface OneToOne {
-
-    /** 
-     * (Optional) The entity class that is the target of 
-     * the association. 
-     *
-     * <p> Defaults to the type of the field or property 
-     * that stores the association. 
-     */
-    Class targetEntity() default void.class;
-
-    /**
-     * (Optional) The operations that must be cascaded to 
-     * the target of the association.
-     *
-     * <p> By default no operations are cascaded.
-     */
-    CascadeType[] cascade() default {};
-
-    /** 
-     * (Optional) Whether the association should be lazily 
-     * loaded or must be eagerly fetched. The {@link FetchType#EAGER EAGER} 
-     * strategy is a requirement on the persistence provider runtime that 
-     * the associated entity must be eagerly fetched. The {@link FetchType#LAZY 
-     * LAZY} strategy is a hint to the persistence provider runtime.
-     */
-    FetchType fetch() default EAGER;
-
-    /** 
-     * (Optional) Whether the association is optional. If set 
-     * to false then a non-null relationship must always exist.
-     */
-    boolean optional() default true;
-
-    /** (Optional) The field that owns the relationship. This 
-      * element is only specified on the inverse (non-owning) 
-      * side of the association.
-     */
-    String mappedBy() default "";
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/OrderBy.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/OrderBy.java b/utils/src/javax/persistence/OrderBy.java
deleted file mode 100644
index 5d7692e..0000000
--- a/utils/src/javax/persistence/OrderBy.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.ElementType.FIELD;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * This annotation specifies the ordering of the elements of a 
- * collection valued association at the point when the association 
- * is retrieved.
- * 
- * <p> The syntax of the <code>value</code> ordering element is an 
- * <code>orderby_list</code>, as follows:
- * 
- * <pre>
- *    orderby_list::= orderby_item [,orderby_item]*
- *    orderby_item::= property_or_field_name [ASC | DESC]
- * </pre>
- * 
- * <p> If <code>ASC</code> or <code>DESC</code> is not specified, 
- * <code>ASC</code> (ascending order) is assumed.
- *
- * <p> If the ordering element is not specified, ordering by 
- * the primary key of the associated entity is assumed.
- *
- * <p> The property or field name must correspond to that of a 
- * persistent property or field of the associated class. The 
- * properties or fields used in the ordering must correspond to 
- * columns for which comparison operators are supported.
- *
- * <pre>
- *    Example:
- *    
- *    &#064;Entity public class Course {
- *     ...
- *     &#064;ManyToMany
- *     &#064;OrderBy("lastname ASC")
- *     public List<Student> getStudents() {...};
- *     ...
- *    }
- *    
- *    &#064;Entity public class Student {
- *      ...
- *      &#064;ManyToMany(mappedBy="students")
- *      &#064;OrderBy // PK is assumed
- *      public List<Course> getCourses() {...};
- *      ...
- *    }
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target({METHOD, FIELD}) 
-@Retention(RUNTIME)
-
-public @interface OrderBy {
-
-    /**
-    * An <code>orderby_list</code>, specified as follows:
-    *
-    * <pre>
-    *    orderby_list::= orderby_item [,orderby_item]*
-    *    orderby_item::= property_or_field_name [ASC | DESC]
-    * </pre>
-    *
-    * <p> If <code>ASC</code> or <code>DESC</code> is not specified,
-    * <code>ASC</code> (ascending order) is assumed.
-    *
-    * <p> If the ordering element is not specified, ordering by
-    * the primary key of the associated entity is assumed.
-    */
-    String value() default "";
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/PersistenceException.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/PersistenceException.java b/utils/src/javax/persistence/PersistenceException.java
deleted file mode 100644
index 7027e9f..0000000
--- a/utils/src/javax/persistence/PersistenceException.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-
-/**
- * Thrown by the persistence provider when a problem occurs.
- * All instances of <code>PersistenceException</code> except for instances of 
- * {@link NoResultException} and {@link NonUniqueResultException} will cause 
- * the current transaction, if one is active, to be marked for rollback.
- *
- * @since Java Persistence 1.0
- */
-@SuppressWarnings("serial")
-public class PersistenceException extends RuntimeException {
-
-        /** 
-         * Constructs a new <code>PersistenceException</code> exception 
-         * with <code>null</code> as its detail message.
-         */
-	public PersistenceException() {
-		super();
-	}
-
-        /** 
-         * Constructs a new <code>PersistenceException</code> exception 
-         * with the specified detail message.
-         * @param   message   the detail message.
-         */
-	public PersistenceException(String message) {
-		super(message);
-	}
-
-        /** 
-         * Constructs a new <code>PersistenceException</code> exception 
-         * with the specified detail message and cause.
-         * @param   message   the detail message.
-         * @param   cause     the cause.
-         */
-	public PersistenceException(String message, Throwable cause) {
-		super(message, cause);
-	}
-	
-        /** 
-         * Constructs a new <code>PersistenceException</code> exception 
-         * with the specified cause.
-         * @param   cause     the cause.
-         */
-	public PersistenceException(Throwable cause) {
-		super(cause);
-	}
-};
-

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/PostLoad.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/PostLoad.java b/utils/src/javax/persistence/PostLoad.java
deleted file mode 100644
index 1960f2d..0000000
--- a/utils/src/javax/persistence/PostLoad.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * Is used to specify callback methods for the corresponding 
- * lifecycle event. This annotation may be applied to methods 
- * of an entity class, a mapped superclass, or a callback 
- * listener class.
- *
- * @since Java Persistence 1.0
- */
-@Target({METHOD}) 
-@Retention(RUNTIME)
-
-public @interface PostLoad {}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/PostPersist.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/PostPersist.java b/utils/src/javax/persistence/PostPersist.java
deleted file mode 100644
index c6682b4..0000000
--- a/utils/src/javax/persistence/PostPersist.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * Is used to specify callback methods for the corresponding 
- * lifecycle event. This annotation may be applied to methods 
- * of an entity class, a mapped superclass, or a callback 
- * listener class.
- *
- * @since Java Persistence 1.0
- */
-@Target({METHOD})
-@Retention(RUNTIME)
-
-public @interface PostPersist {}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/PostRemove.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/PostRemove.java b/utils/src/javax/persistence/PostRemove.java
deleted file mode 100644
index 36e5699..0000000
--- a/utils/src/javax/persistence/PostRemove.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * Is used to specify callback methods for the corresponding 
- * lifecycle event. This annotation may be applied to methods 
- * of an entity class, a mapped superclass, or a callback 
- * listener class.
- *
- * @since Java Persistence 1.0
- */
-@Target({METHOD})
-@Retention(RUNTIME)
-
-public @interface PostRemove {}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/PostUpdate.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/PostUpdate.java b/utils/src/javax/persistence/PostUpdate.java
deleted file mode 100644
index 9235a5e..0000000
--- a/utils/src/javax/persistence/PostUpdate.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * Is used to specify callback methods for the corresponding 
- * lifecycle event. This annotation may be applied to methods 
- * of an entity class, a mapped superclass, or a callback 
- * listener class.
- *
- * @since Java Persistence 1.0
- */
-@Target({METHOD})
-@Retention(RUNTIME)
-
-public @interface PostUpdate {}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/PrimaryKeyJoinColumn.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/PrimaryKeyJoinColumn.java b/utils/src/javax/persistence/PrimaryKeyJoinColumn.java
deleted file mode 100644
index f4bbb65..0000000
--- a/utils/src/javax/persistence/PrimaryKeyJoinColumn.java
+++ /dev/null
@@ -1,120 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.ElementType.FIELD;
-import static java.lang.annotation.ElementType.TYPE;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * This annotation specifies a primary key column that is used 
- * as a foreign key to join to another table. 
- *
- * <p> It is used to join the primary table of an entity subclass 
- * in the {@link InheritanceType#JOINED JOINED} mapping strategy 
- * to the primary table of its superclass; it is used within a 
- * {@link SecondaryTable} annotation to join a secondary table 
- * to a primary table; and it may be used in a {@link OneToOne} 
- * mapping in which the primary key of the referencing entity 
- * is used as a foreign key to the referenced entity. 
- *
- * <p> If no <code>PrimaryKeyJoinColumn</code> annotation is 
- * specified for a subclass in the {@link InheritanceType#JOINED 
- * JOINED} mapping strategy, the foreign key columns are assumed 
- * to have the same names as the primary key columns of the 
- * primary table of the superclass
- *
- * <pre>
- *
- *    Example: Customer and ValuedCustomer subclass
- *
- *    &#064;Entity
- *    &#064;Table(name="CUST")
- *    &#064;Inheritance(strategy=JOINED)
- *    &#064;DiscriminatorValue("CUST")
- *    public class Customer { ... }
- *    
- *    &#064;Entity
- *    &#064;Table(name="VCUST")
- *    &#064;DiscriminatorValue("VCUST")
- *    &#064;PrimaryKeyJoinColumn(name="CUST_ID")
- *    public class ValuedCustomer extends Customer { ... }
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target({TYPE, METHOD, FIELD})
-@Retention(RUNTIME)
-
-public @interface PrimaryKeyJoinColumn {
-
-    /** 
-     * The name of the primary key column of the current table.
-     * <p> Defaults to the same name as the primary key column 
-     * of the primary table of the superclass ({@link 
-     * InheritanceType#JOINED JOINED} mapping strategy); the same 
-     * name as the primary key column of the primary table 
-     * ({@link SecondaryTable} mapping); or the same name as the 
-     * primary key column for the table for the referencing entity 
-     * ({@link OneToOne} mapping)
-     */
-    String name() default "";
-
-    /** 
-     * (Optional) The name of the primary key column of the table 
-     * being joined to.
-     * <p> Defaults to the same name as the primary key column 
-     * of the primary table of the superclass ({@link 
-     * InheritanceType#JOINED JOINED} mapping strategy); the same 
-     * name as the primary key column of the primary table 
-     * ({@link SecondaryTable} mapping); or the same name as the 
-     * primary key column for the table for the referencing entity 
-     * ({@link OneToOne} mapping)
-     */
-    String referencedColumnName() default "";
-
-    /**
-     * (Optional) The SQL fragment that is used when generating the 
-     * DDL for the column. This should not be specified for a 
-     * {@link OneToOne} primary key association.
-     * <p> Defaults to the generated SQL to create a column of the 
-     * inferred type.
-     */
-    String columnDefinition() default "";
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/PrimaryKeyJoinColumns.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/PrimaryKeyJoinColumns.java b/utils/src/javax/persistence/PrimaryKeyJoinColumns.java
deleted file mode 100644
index 1d418e4..0000000
--- a/utils/src/javax/persistence/PrimaryKeyJoinColumns.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.ElementType.FIELD;
-import static java.lang.annotation.ElementType.TYPE;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * This annotation groups {@link PrimaryKeyJoinColumn} annotations.
- * It is used to map composite foreign keys.
- *
- * <pre>
- *    Example 1: ValuedCustomer subclass
- *
- *    &#064;Entity
- *    &#064;Table(name="VCUST")
- *    &#064;DiscriminatorValue("VCUST")
- *    &#064;PrimaryKeyJoinColumns({
- *        &#064;PrimaryKeyJoinColumn(name="CUST_ID", 
- *            referencedColumnName="ID"),
- *        &#064;PrimaryKeyJoinColumn(name="CUST_TYPE",
- *            referencedColumnName="TYPE")
- *    })
- *    public class ValuedCustomer extends Customer { ... }
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target({TYPE, METHOD, FIELD})
-@Retention(RUNTIME)
-
-public @interface PrimaryKeyJoinColumns {
-
-    /** One or more {@link PrimaryKeyJoinColumn} annotations. */
-    PrimaryKeyJoinColumn[] value();
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/SecondaryTable.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/SecondaryTable.java b/utils/src/javax/persistence/SecondaryTable.java
deleted file mode 100644
index 3942528..0000000
--- a/utils/src/javax/persistence/SecondaryTable.java
+++ /dev/null
@@ -1,120 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.TYPE;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * This annotation is used to specify a secondary table for 
- * the annotated entity class. Specifying one or more secondary 
- * tables indicates that the data for the entity class is stored 
- * across multiple tables.
- *
- * <p> If no <code>SecondaryTable</code> annotation is specified, 
- * it is assumed that all persistent fields or properties of the 
- * entity are mapped to the primary table. If no primary key join 
- * columns are specified, the join columns are assumed to reference 
- * the primary key columns of the primary table, and have the same 
- * names and types as the referenced primary key columns of the 
- * primary table.
- *
- * <pre>
- * Example 1: Single secondary table with a single primary key column.
- *
- *    &#064;Entity
- *    &#064;Table(name="CUSTOMER")
- *    &#064;SecondaryTable(name="CUST_DETAIL", 
- *        pkJoinColumns=&#064;PrimaryKeyJoinColumn(name="CUST_ID"))
- *    public class Customer { ... } 
- *
- *    Example 2: Single secondary table with multiple primary key columns.
- *
- *    &#064;Entity
- *    &#064;Table(name="CUSTOMER")
- *    &#064;SecondaryTable(name="CUST_DETAIL",
- *        pkJoinColumns={
- *            &#064;PrimaryKeyJoinColumn(name="CUST_ID"),
- *            &#064;PrimaryKeyJoinColumn(name="CUST_TYPE")})
- *    public class Customer { ... }
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target(TYPE) 
-@Retention(RUNTIME)
-
-public @interface SecondaryTable {
-
-    /** (Required) The name of the table. */
-    String name();
-
-    /** (Optional) The catalog of the table.
-     * <p> Defaults to the default catalog.
-     */
-    String catalog() default "";
-
-    /** (Optional) The schema of the table.
-     * <p> Defaults to the default schema for user.
-     */
-    String schema() default "";
-
-    /** 
-     * (Optional) The columns that are used to join with 
-     * the primary table.
-     * <p> Defaults to the column(s) of the same name(s) 
-     * as the primary key column(s) in the primary table
-     */
-    PrimaryKeyJoinColumn[] pkJoinColumns() default {};
-
-    /**
-     * (Optional) Unique constraints that are to be placed on the 
-     * table. These are typically only used if table generation 
-     * is in effect. These constraints apply in addition to any 
-     * constraints specified by the {@link Column} and {@link JoinColumn} 
-     * annotations and constraints entailed by primary key mappings.
-     * <p> Defaults to no additional constraints.
-     */
-    UniqueConstraint[] uniqueConstraints() default {};
-
-    /**
-     * (Optional) join type (supports inner, left, right) to use
-     * for querying data from the joined tables.
-     */
-    String join() default "";
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/SecondaryTables.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/SecondaryTables.java b/utils/src/javax/persistence/SecondaryTables.java
deleted file mode 100644
index 4cdaf44..0000000
--- a/utils/src/javax/persistence/SecondaryTables.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.TYPE;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * This annotation is used to specify multiple secondary tables 
- * for an entity.
- *
- * <pre>
- *    Example 1: Multiple secondary tables assuming primary key columns are named the same in all tables.
- *
- *    &#064;Entity
- *    &#064;Table(name="EMPLOYEE")
- *    &#064;SecondaryTables({
- *        &#064;SecondaryTable(name="EMP_DETAIL"),
- *        &#064;SecondaryTable(name="EMP_HIST")
- *    })
- *    public class Employee { ... }
- *    
- *    Example 2: Multiple secondary tables with differently named primary key columns. 
- *
- *    &#064;Entity
- *    &#064;Table(name="EMPLOYEE")
- *    &#064;SecondaryTables({
- *        &#064;SecondaryTable(name="EMP_DETAIL", 
- *            pkJoinColumns=&#064;PrimaryKeyJoinColumn(name="EMPL_ID")),
- *        &#064;SecondaryTable(name="EMP_HIST", 
- *            pkJoinColumns=&#064;PrimaryKeyJoinColumn(name="EMPLOYEE_ID"))
- *    })
- *    public class Employee { ... }
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target(TYPE) 
-@Retention(RUNTIME)
-
-public @interface SecondaryTables {
-
-    /** The secondary tables for an entity. */
-    SecondaryTable[] value();
-}

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/457f3b3d/utils/src/javax/persistence/SequenceGenerator.java
----------------------------------------------------------------------
diff --git a/utils/src/javax/persistence/SequenceGenerator.java b/utils/src/javax/persistence/SequenceGenerator.java
deleted file mode 100644
index 362740c..0000000
--- a/utils/src/javax/persistence/SequenceGenerator.java
+++ /dev/null
@@ -1,91 +0,0 @@
-/*
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
- * 
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
- * 
- * The contents of this file are subject to the terms of either the GNU
- * General Public License Version 2 only ("GPL") or the Common Development
- * and Distribution License("CDDL") (collectively, the "License").  You
- * may not use this file except in compliance with the License. You can obtain
- * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
- * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific
- * language governing permissions and limitations under the License.
- * 
- * When distributing the software, include this License Header Notice in each
- * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
- * Sun designates this particular file as subject to the "Classpath" exception
- * as provided by Sun in the GPL Version 2 section of the License file that
- * accompanied this code.  If applicable, add the following below the License
- * Header, with the fields enclosed by brackets [] replaced by your own
- * identifying information: "Portions Copyrighted [year]
- * [name of copyright owner]"
- * 
- * Contributor(s):
- * 
- * If you wish your version of this file to be governed by only the CDDL or
- * only the GPL Version 2, indicate your decision by adding "[Contributor]
- * elects to include this software in this distribution under the [CDDL or GPL
- * Version 2] license."  If you don't indicate a single choice of license, a
- * recipient has the option to distribute your version of this file under
- * either the CDDL, the GPL Version 2 or to extend the choice of license to
- * its licensees as provided above.  However, if you add GPL Version 2 code
- * and therefore, elected the GPL Version 2 license, then the option applies
- * only if the new code is made subject to such option by the copyright
- * holder.
- */
-package javax.persistence;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.Retention;
-import static java.lang.annotation.ElementType.METHOD;
-import static java.lang.annotation.ElementType.FIELD;
-import static java.lang.annotation.ElementType.TYPE;
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-
-/**
- * This annotation defines a primary key generator that may 
- * be referenced by name when a generator element is specified 
- * for the {@link GeneratedValue} annotation. A sequence generator 
- * may be specified on the entity class or on the primary key 
- * field or property. The scope of the generator name is global 
- * to the persistence unit (across all generator types).
- *
- * <pre>
- *   Example:
- *
- *   &#064;SequenceGenerator(name="EMP_SEQ", allocationSize=25)
- * </pre>
- *
- * @since Java Persistence 1.0
- */
-@Target({TYPE, METHOD, FIELD}) 
-@Retention(RUNTIME)
-
-public @interface SequenceGenerator {
-
-    /** 
-     * (Required) A unique generator name that can be referenced 
-     * by one or more classes to be the generator for primary key 
-     * values.
-     */
-    String name();
-
-    /**
-     * (Optional) The name of the database sequence object from 
-     * which to obtain primary key values.
-     * <p> Defaults to a provider-chosen value.
-     */
-    String sequenceName() default "";
-
-    /** 
-     * (Optional) The value from which the sequence object 
-     * is to start generating.
-     */
-    int initialValue() default 1;
-
-    /**
-     * (Optional) The amount to increment by when allocating 
-     * sequence numbers from the sequence.
-     */
-    int allocationSize() default 50;
-}