Code formating and whitespace cleanup
[jpim.git] / src / de / j32 / pimstuff / data / Entry.java
index 909cd3b..9f96731 100644 (file)
@@ -8,68 +8,71 @@ import de.j32.util.FilteredIterator;
 
 public class Entry
 {
-       long id_ = 0;
-       String name_ = "";
-       ArrayList<Attribute> attributes_ = new ArrayList<Attribute>();
+    long id_ = 0;
+    String name_ = "";
+    ArrayList<Attribute> attributes_ = new ArrayList<Attribute>();
 
-       public void name(String name)
-       {
-               name_ = name;
-       }
-       
-       public String name()
-       {
-               return name_;
-       }
-       
-       public void id(long id)
-       {
-               id_ = id;
-       }
-       
-       public long id()
-       {
-               return id_;
-       }
-       
-       public void attribute(String type, String rel, String value)
-       {
-               attributes_.add(new Attribute(type, rel, value,attributes_.size()));
-       }
+    public void name(String name)
+    {
+        name_ = name;
+    }
 
-       public Iterable<Attribute> attributes()
-       {
-               return attributes_;
-       }
-       
-       public Iterable<Attribute> attributes(final String type)
-       {
-               return new Iterable<Attribute>() {
-                       public Iterator<Attribute> iterator() {
-                               return new FilteredIterator<Attribute>(
-                                               attributes_.iterator(),
-                                               new Filter<Attribute>() {
-                                                       public boolean match(Attribute element) {
-                                                               return element.type == type;
-                                                       }
-                                               });
-                       }
-               };
-       }
-       
-       public Iterable<Attribute> attributes(final String type, final String rel)
-       {
-               return new Iterable<Attribute>() {
-                       public Iterator<Attribute> iterator() {
-                               return new FilteredIterator<Attribute>(
-                                               attributes_.iterator(),
-                                               new Filter<Attribute>() {
-                                                       public boolean match(Attribute element) {
-                                                               return element.type == type && element.rel == rel;
-                                                       }
-                                               });
-                       }
-               };
-       }
+    public String name()
+    {
+        return name_;
+    }
+
+    public void id(long id)
+    {
+        id_ = id;
+    }
+
+    public long id()
+    {
+        return id_;
+    }
+
+    public void attribute(String type, String rel, String value)
+    {
+        attributes_.add(new Attribute(type, rel, value, attributes_.size()));
+    }
+
+    public Iterable<Attribute> attributes()
+    {
+        return attributes_;
+    }
+
+    public Iterable<Attribute> attributes(final String type)
+    {
+        return new Iterable<Attribute>() {
+            public Iterator<Attribute> iterator()
+            {
+                return new FilteredIterator<Attribute>(attributes_.iterator(),
+                        new Filter<Attribute>() {
+                            public boolean match(Attribute element)
+                            {
+                                return element.type == type;
+                            }
+                        });
+            }
+        };
+    }
+
+    public Iterable<Attribute> attributes(final String type, final String rel)
+    {
+        return new Iterable<Attribute>() {
+            public Iterator<Attribute> iterator()
+            {
+                return new FilteredIterator<Attribute>(attributes_.iterator(),
+                        new Filter<Attribute>() {
+                            public boolean match(Attribute element)
+                            {
+                                return element.type == type
+                                        && element.rel == rel;
+                            }
+                        });
+            }
+        };
+    }
 
 }