Author: veithen
Date: Mon Jan  8 01:33:51 2018
New Revision: 1820514

URL: http://svn.apache.org/viewvc?rev=1820514&view=rev
Log:
Normalize whitespace.

Modified:
    
axis/axis2/java/core/trunk/modules/kernel/src/org/apache/axis2/description/PolicySubject.java

Modified: 
axis/axis2/java/core/trunk/modules/kernel/src/org/apache/axis2/description/PolicySubject.java
URL: 
http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/kernel/src/org/apache/axis2/description/PolicySubject.java?rev=1820514&r1=1820513&r2=1820514&view=diff
==============================================================================
--- 
axis/axis2/java/core/trunk/modules/kernel/src/org/apache/axis2/description/PolicySubject.java
 (original)
+++ 
axis/axis2/java/core/trunk/modules/kernel/src/org/apache/axis2/description/PolicySubject.java
 Mon Jan  8 01:33:51 2018
@@ -32,110 +32,110 @@ import java.util.concurrent.ConcurrentHa
 
 public class PolicySubject {
 
-       private boolean updated = false;
-       private Date lastUpdatedTime = new Date();
-       
-       private ConcurrentHashMap<String, PolicyComponent> 
attachedPolicyComponents = new ConcurrentHashMap<String, PolicyComponent>();
-
-       public void attachPolicy(Policy policy) {
-               String key = policy.getName();
-               if (key == null) {
-                       key = policy.getId();
-                       if (key == null) {
-                               key = UIDGenerator.generateUID();
-                               policy.setId(key);
-                       }
-               }
-               attachPolicyComponent(key, policy);
-       }
-
-       public void attachPolicyReference(PolicyReference reference) {
-               attachedPolicyComponents.put(reference.getURI(), reference);
-               setLastUpdatedTime(new Date()); 
-       }
-
-       public void attachPolicyComponents(List<PolicyComponent> 
policyComponents) {
-               for (Iterator<PolicyComponent> iterator = 
policyComponents.iterator(); iterator
-                               .hasNext();) {
-                       attachPolicyComponent((PolicyComponent) 
iterator.next());
-               }
-       }
-
-       public void attachPolicyComponent(PolicyComponent policyComponent) {
-               if (policyComponent instanceof Policy) {
-                       attachPolicy((Policy) policyComponent);
-               } else if (policyComponent instanceof PolicyReference) {
-                       attachPolicyReference((PolicyReference) 
policyComponent);
-               } else {
-                       throw new IllegalArgumentException(
-                                       "Invalid top level policy component 
type");
-               }
-
-       }
-
-       public void attachPolicyComponent(String key,
-                       PolicyComponent policyComponent) {
-               attachedPolicyComponents.put(key, policyComponent);
-               setLastUpdatedTime(new Date());
-               
-               if (!isUpdated()) {
-                       setUpdated(true);
-               }
-       }
-
-       public PolicyComponent getAttachedPolicyComponent(String key) {
-               return (PolicyComponent) attachedPolicyComponents.get(key);
-
-       }
-
-       public Collection<PolicyComponent> getAttachedPolicyComponents() {
-               return attachedPolicyComponents.values();
-       }
-
-       public boolean isUpdated() {
-               return updated;
-       }
-
-       public void setUpdated(boolean updated) {
-               this.updated = updated;
-       }
-
-       public void updatePolicy(Policy policy) {
-               String key = (policy.getName() != null) ? policy.getName() : 
policy
-                               .getId();
-               if (key == null) {
-                       throw new IllegalArgumentException(
-                                       "policy doesn't have a name or an id ");
-               }
-               attachedPolicyComponents.put(key, policy);
-               setLastUpdatedTime(new Date());
-               
-               if (!isUpdated()) {
-                       setUpdated(true);
-               }
-       }
-
-       public void detachPolicyComponent(String key) {
-               attachedPolicyComponents.remove(key);
-               setLastUpdatedTime(new Date());
-               if (!isUpdated()) {
-                       setUpdated(true);
-               }
-       }
-
-       public void clear() {
-               attachedPolicyComponents.clear();
-               setLastUpdatedTime(new Date());
-               if (!isUpdated()) {
-                       setUpdated(true);
-               }
-       }
-
-       public Date getLastUpdatedTime() {
-               return lastUpdatedTime;
-       }
-
-       public void setLastUpdatedTime(Date lastUpdatedTime) {
-               this.lastUpdatedTime = lastUpdatedTime;
-       }
+    private boolean updated = false;
+    private Date lastUpdatedTime = new Date();
+    
+    private ConcurrentHashMap<String, PolicyComponent> 
attachedPolicyComponents = new ConcurrentHashMap<String, PolicyComponent>();
+
+    public void attachPolicy(Policy policy) {
+        String key = policy.getName();
+        if (key == null) {
+            key = policy.getId();
+            if (key == null) {
+                key = UIDGenerator.generateUID();
+                policy.setId(key);
+            }
+        }
+        attachPolicyComponent(key, policy);
+    }
+
+    public void attachPolicyReference(PolicyReference reference) {
+        attachedPolicyComponents.put(reference.getURI(), reference);
+        setLastUpdatedTime(new Date()); 
+    }
+
+    public void attachPolicyComponents(List<PolicyComponent> policyComponents) 
{
+        for (Iterator<PolicyComponent> iterator = policyComponents.iterator(); 
iterator
+                .hasNext();) {
+            attachPolicyComponent((PolicyComponent) iterator.next());
+        }
+    }
+
+    public void attachPolicyComponent(PolicyComponent policyComponent) {
+        if (policyComponent instanceof Policy) {
+            attachPolicy((Policy) policyComponent);
+        } else if (policyComponent instanceof PolicyReference) {
+            attachPolicyReference((PolicyReference) policyComponent);
+        } else {
+            throw new IllegalArgumentException(
+                    "Invalid top level policy component type");
+        }
+
+    }
+
+    public void attachPolicyComponent(String key,
+            PolicyComponent policyComponent) {
+        attachedPolicyComponents.put(key, policyComponent);
+        setLastUpdatedTime(new Date());
+        
+        if (!isUpdated()) {
+            setUpdated(true);
+        }
+    }
+
+    public PolicyComponent getAttachedPolicyComponent(String key) {
+        return (PolicyComponent) attachedPolicyComponents.get(key);
+
+    }
+
+    public Collection<PolicyComponent> getAttachedPolicyComponents() {
+        return attachedPolicyComponents.values();
+    }
+
+    public boolean isUpdated() {
+        return updated;
+    }
+
+    public void setUpdated(boolean updated) {
+        this.updated = updated;
+    }
+
+    public void updatePolicy(Policy policy) {
+        String key = (policy.getName() != null) ? policy.getName() : policy
+                .getId();
+        if (key == null) {
+            throw new IllegalArgumentException(
+                    "policy doesn't have a name or an id ");
+        }
+        attachedPolicyComponents.put(key, policy);
+        setLastUpdatedTime(new Date());
+        
+        if (!isUpdated()) {
+            setUpdated(true);
+        }
+    }
+
+    public void detachPolicyComponent(String key) {
+        attachedPolicyComponents.remove(key);
+        setLastUpdatedTime(new Date());
+        if (!isUpdated()) {
+            setUpdated(true);
+        }
+    }
+
+    public void clear() {
+        attachedPolicyComponents.clear();
+        setLastUpdatedTime(new Date());
+        if (!isUpdated()) {
+            setUpdated(true);
+        }
+    }
+
+    public Date getLastUpdatedTime() {
+        return lastUpdatedTime;
+    }
+
+    public void setLastUpdatedTime(Date lastUpdatedTime) {
+        this.lastUpdatedTime = lastUpdatedTime;
+    }
 }


Reply via email to