From 790ebb5da013497c302fba1e79510515b5d58c61 Mon Sep 17 00:00:00 2001
From: Mic <misvy@vmware.com>
Date: Thu, 14 Feb 2013 22:53:50 +0800
Subject: [PATCH] improved javadoc for jpa implementation

---
 .../jpa/JpaOwnerRepositoryImpl.java           | 21 ++++++++++++++-----
 .../repository/jpa/JpaPetRepositoryImpl.java  | 19 ++++++++++++++---
 .../repository/jpa/JpaVetRepositoryImpl.java  | 21 +++++++++++++++----
 .../jpa/JpaVisitRepositoryImpl.java           | 17 +++++++++++++--
 .../springdatajpa/JpaOwnerRepositoryImpl.java |  2 --
 5 files changed, 64 insertions(+), 16 deletions(-)

diff --git a/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaOwnerRepositoryImpl.java b/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaOwnerRepositoryImpl.java
index ab679d2..8989980 100644
--- a/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaOwnerRepositoryImpl.java
+++ b/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaOwnerRepositoryImpl.java
@@ -1,3 +1,18 @@
+/*
+ * Copyright 2002-2013 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
 package org.springframework.samples.petclinic.repository.jpa;
 
 import java.util.Collection;
@@ -9,12 +24,9 @@ import javax.persistence.Query;
 import org.springframework.samples.petclinic.model.Owner;
 import org.springframework.samples.petclinic.repository.OwnerRepository;
 import org.springframework.stereotype.Repository;
-import org.springframework.transaction.annotation.Transactional;
 
 /**
- * JPA implementation of the ClinicService interface using EntityManager.
- *
- * <p>The mappings are defined in "orm.xml" located in the META-INF directory.
+ * JPA implementation of the {@link OwnerRepository} interface.
  *
  * @author Mike Keith
  * @author Rod Johnson
@@ -23,7 +35,6 @@ import org.springframework.transaction.annotation.Transactional;
  * @since 22.4.2006
  */
 @Repository
-@Transactional
 public class JpaOwnerRepositoryImpl implements OwnerRepository {
 
 	@PersistenceContext
diff --git a/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaPetRepositoryImpl.java b/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaPetRepositoryImpl.java
index 84e9705..c83fd69 100644
--- a/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaPetRepositoryImpl.java
+++ b/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaPetRepositoryImpl.java
@@ -1,3 +1,18 @@
+/*
+ * Copyright 2002-2013 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
 package org.springframework.samples.petclinic.repository.jpa;
 
 import java.util.List;
@@ -11,9 +26,7 @@ import org.springframework.samples.petclinic.repository.PetRepository;
 import org.springframework.stereotype.Repository;
 
 /**
- * JPA implementation of the ClinicService interface using EntityManager.
- *
- * <p>The mappings are defined in "orm.xml" located in the META-INF directory.
+ * JPA implementation of the {@link PetRepository} interface.
  *
  * @author Mike Keith
  * @author Rod Johnson
diff --git a/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaVetRepositoryImpl.java b/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaVetRepositoryImpl.java
index 82bfb7e..b32abc7 100644
--- a/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaVetRepositoryImpl.java
+++ b/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaVetRepositoryImpl.java
@@ -1,3 +1,18 @@
+/*
+ * Copyright 2002-2013 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
 package org.springframework.samples.petclinic.repository.jpa;
 
 import java.util.Collection;
@@ -11,10 +26,8 @@ import org.springframework.samples.petclinic.repository.VetRepository;
 import org.springframework.stereotype.Repository;
 
 /**
- * JPA implementation of the ClinicService interface using EntityManager.
- *
- * <p>The mappings are defined in "orm.xml" located in the META-INF directory.
- *
+* JPA implementation of the {@link VetRepository} interface.
+  *
  * @author Mike Keith
  * @author Rod Johnson
  * @author Sam Brannen
diff --git a/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaVisitRepositoryImpl.java b/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaVisitRepositoryImpl.java
index 0c6630c..ff43486 100644
--- a/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaVisitRepositoryImpl.java
+++ b/src/main/java/org/springframework/samples/petclinic/repository/jpa/JpaVisitRepositoryImpl.java
@@ -1,7 +1,20 @@
+/*
+ * Copyright 2002-2013 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
 package org.springframework.samples.petclinic.repository.jpa;
 
-
-
 import java.util.List;
 
 import javax.persistence.EntityManager;
diff --git a/src/main/java/org/springframework/samples/petclinic/repository/springdatajpa/JpaOwnerRepositoryImpl.java b/src/main/java/org/springframework/samples/petclinic/repository/springdatajpa/JpaOwnerRepositoryImpl.java
index eb67277..6f28d79 100644
--- a/src/main/java/org/springframework/samples/petclinic/repository/springdatajpa/JpaOwnerRepositoryImpl.java
+++ b/src/main/java/org/springframework/samples/petclinic/repository/springdatajpa/JpaOwnerRepositoryImpl.java
@@ -24,7 +24,6 @@ import javax.persistence.Query;
 import org.springframework.samples.petclinic.model.Owner;
 import org.springframework.samples.petclinic.repository.OwnerRepository;
 import org.springframework.stereotype.Repository;
-import org.springframework.transaction.annotation.Transactional;
 
 /**
  * Using native JPA instead of Spring Data JPA here because of this query:
@@ -34,7 +33,6 @@ import org.springframework.transaction.annotation.Transactional;
  * @author Michael Isvy
  */
 @Repository
-@Transactional
 public class JpaOwnerRepositoryImpl implements OwnerRepository {
 
 	@PersistenceContext
-- 
GitLab