diff options
| author | Andrew Branson <andrew.branson@cern.ch> | 2014-10-03 17:30:41 +0200 |
|---|---|---|
| committer | Andrew Branson <andrew.branson@cern.ch> | 2014-10-03 17:30:41 +0200 |
| commit | 275d0bbf555c8917be82ce4cc21eb4cabb00f4c5 (patch) | |
| tree | ddcc6b14077d90d1b970b67829f07120547dbb62 /src/main/java/com/c2kernel/property | |
| parent | a139f95bfeca603333b8c0310ae09c6805e58584 (diff) | |
Huge exception overhaul: Merged ClusterStorageException with
PersistencyException. Replaced MembershipException with
InvalidCollectionModification CORBA Exception. Made all predef steps
throw more accurate exceptions when they go wrong, and let more
exceptions bubble through from underneath.
Diffstat (limited to 'src/main/java/com/c2kernel/property')
| -rw-r--r-- | src/main/java/com/c2kernel/property/PropertyDescriptionList.java | 6 | ||||
| -rw-r--r-- | src/main/java/com/c2kernel/property/PropertyUtility.java | 6 |
2 files changed, 6 insertions, 6 deletions
diff --git a/src/main/java/com/c2kernel/property/PropertyDescriptionList.java b/src/main/java/com/c2kernel/property/PropertyDescriptionList.java index a5c6d57..a4e226d 100644 --- a/src/main/java/com/c2kernel/property/PropertyDescriptionList.java +++ b/src/main/java/com/c2kernel/property/PropertyDescriptionList.java @@ -23,7 +23,7 @@ package com.c2kernel.property; import java.util.ArrayList;
import java.util.HashMap;
-import com.c2kernel.common.InvalidDataException;
+import com.c2kernel.common.InvalidData;
import com.c2kernel.utils.CastorArrayList;
public class PropertyDescriptionList extends CastorArrayList<PropertyDescription>
@@ -68,12 +68,12 @@ public class PropertyDescriptionList extends CastorArrayList<PropertyDescription return false;
}
- public PropertyArrayList instantiate(PropertyArrayList initProps) throws InvalidDataException {
+ public PropertyArrayList instantiate(PropertyArrayList initProps) throws InvalidData {
// check that supplied init properties exist in desc list
HashMap<String, String> validatedInitProps = new HashMap<String, String>();
for (Property initProp : initProps.list) {
if (!definesProperty(initProp.getName()))
- throw new InvalidDataException("Property "+initProp.getName()+" has not been declared in the property descriptions", "");
+ throw new InvalidData("Property "+initProp.getName()+" has not been declared in the property descriptions");
else
validatedInitProps.put(initProp.getName(), initProp.getValue());
}
diff --git a/src/main/java/com/c2kernel/property/PropertyUtility.java b/src/main/java/com/c2kernel/property/PropertyUtility.java index 02daf47..b345962 100644 --- a/src/main/java/com/c2kernel/property/PropertyUtility.java +++ b/src/main/java/com/c2kernel/property/PropertyUtility.java @@ -23,7 +23,7 @@ package com.c2kernel.property; import java.util.ArrayList;
import java.util.Iterator;
-import com.c2kernel.common.ObjectNotFoundException;
+import com.c2kernel.common.ObjectNotFound;
import com.c2kernel.lookup.ItemPath;
import com.c2kernel.persistency.ClusterStorage;
import com.c2kernel.persistency.outcome.Outcome;
@@ -66,7 +66,7 @@ public class PropertyUtility }
- static public PropertyDescriptionList getPropertyDescriptionOutcome(ItemPath itemPath, String descVer) throws ObjectNotFoundException
+ static public PropertyDescriptionList getPropertyDescriptionOutcome(ItemPath itemPath, String descVer) throws ObjectNotFound
{
try
{
@@ -76,7 +76,7 @@ public class PropertyUtility catch (Exception ex)
{
Logger.error(ex);
- throw new ObjectNotFoundException("Problem getting PropertyDescription from "+itemPath, "");
+ throw new ObjectNotFound("Could not fetch PropertyDescription from "+itemPath);
}
}
|
