]> git.mxchange.org Git - jfinancials-ejb.git/commitdiff
Maybe cherry-pick:
authorRoland Häder <roland@mxchange.org>
Wed, 1 Nov 2017 21:37:17 +0000 (22:37 +0100)
committerRoland Häder <roland@mxchange.org>
Wed, 1 Nov 2017 21:37:17 +0000 (22:37 +0100)
- renamed <product|category>Title to <product|category>I18nKey

Signed-off-by: Roland Häder <roland@mxchange.org>
src/java/org/mxchange/jproduct/model/category/FinancialsAdminProductCategorySessionBean.java
src/java/org/mxchange/jproduct/model/product/FinancialsAdminGenericProductSessionBean.java

index 2766a5bc5a4b43d449b1c41f5e34c5a655dcb91b..aa4483bddd9e921d03e33a72dd4fe13241d81bee 100644 (file)
@@ -63,10 +63,10 @@ public class FinancialsAdminProductCategorySessionBean extends BaseFinancialsPro
                        throw new NullPointerException("category is null"); //NOI18N
                } else if (category.getCategoryI18nKey() == null) {
                        // Throw it again
-                       throw new NullPointerException("category.categoryTitle is null"); //NOI18N
+                       throw new NullPointerException("category.categoryI18nKey is null"); //NOI18N
                } else if (category.getCategoryI18nKey().isEmpty()) {
                        // Throw it again
-                       throw new IllegalArgumentException("category.categoryTitle is empty"); //NOI18N
+                       throw new IllegalArgumentException("category.categoryI18nKey is empty"); //NOI18N
                } else if (category.getCategoryId() != null) {
                        // Throw IAE
                        throw new IllegalArgumentException(MessageFormat.format("category.categoryId={0} is not expected.", category.getCategoryId())); //NOI18N
@@ -111,10 +111,10 @@ public class FinancialsAdminProductCategorySessionBean extends BaseFinancialsPro
                        throw new NullPointerException("category is null"); //NOI18N
                } else if (category.getCategoryI18nKey() == null) {
                        // Throw it again
-                       throw new NullPointerException("category.categoryTitle is null"); //NOI18N
+                       throw new NullPointerException("category.categoryI18nKey is null"); //NOI18N
                } else if (category.getCategoryI18nKey().isEmpty()) {
                        // Throw it again
-                       throw new IllegalArgumentException("category.categoryTitle is empty"); //NOI18N
+                       throw new IllegalArgumentException("category.categoryI18nKey is empty"); //NOI18N
                } else if (category.getCategoryId() != null) {
                        // Throw IAE
                        throw new IllegalArgumentException(MessageFormat.format("category.categoryId={0} is not expected.", category.getCategoryId())); //NOI18N
index 3ce7eacd59950b32803e5e66e4d869d8fd718720..44767567a26d900ed8d2de163ceff8fba7a915f1 100644 (file)
@@ -55,12 +55,12 @@ public class FinancialsAdminGenericProductSessionBean extends BaseFinancialsProd
                if (null == product) {
                        // Throw NPE
                        throw new NullPointerException("product is null"); //NOI18N
-               } else if (product.getProductTitle() == null) {
+               } else if (product.getProductI18nKey() == null) {
                        // Throw it again
-                       throw new NullPointerException("product.productTitle is null"); //NOI18N
-               } else if (product.getProductTitle().isEmpty()) {
+                       throw new NullPointerException("product.productI18nKey is null"); //NOI18N
+               } else if (product.getProductI18nKey().isEmpty()) {
                        // Throw it again
-                       throw new IllegalArgumentException("product.productTitle is empty"); //NOI18N
+                       throw new IllegalArgumentException("product.productI18nKey is empty"); //NOI18N
                } else if (product.getProductId() != null) {
                        // Throw IAE
                        throw new IllegalArgumentException(MessageFormat.format("product.productId={0} is not expected.", product.getProductId())); //NOI18N
@@ -124,12 +124,12 @@ public class FinancialsAdminGenericProductSessionBean extends BaseFinancialsProd
                if (null == product) {
                        // Throw NPE
                        throw new NullPointerException("product is null"); //NOI18N
-               } else if (product.getProductTitle() == null) {
+               } else if (product.getProductI18nKey() == null) {
                        // Throw it again
-                       throw new NullPointerException("product.productTitle is null"); //NOI18N
-               } else if (product.getProductTitle().isEmpty()) {
+                       throw new NullPointerException("product.productI18nKey is null"); //NOI18N
+               } else if (product.getProductI18nKey().isEmpty()) {
                        // Throw it again
-                       throw new IllegalArgumentException("product.productTitle is empty"); //NOI18N
+                       throw new IllegalArgumentException("product.productI18nKey is empty"); //NOI18N
                } else if (product.getProductId() != null) {
                        // Throw IAE
                        throw new IllegalArgumentException(MessageFormat.format("product.productId={0} is not expected.", product.getProductId())); //NOI18N
@@ -144,7 +144,7 @@ public class FinancialsAdminGenericProductSessionBean extends BaseFinancialsProd
                // Check each entry
                for (final Product createdProduct : list) {
                        // Is same name?
-                       if (Objects.equals(createdProduct.getProductTitle(), product.getProductTitle())) {
+                       if (Objects.equals(createdProduct.getProductI18nKey(), product.getProductI18nKey())) {
                                // Found it, then stop here
                                isFound = true;
                                break;