|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.ibm.di.server.Compare
public class Compare
This class is used for making comparisons of entries and attributes.
| Constructor Summary | |
|---|---|
Compare()
|
|
| Method Summary | |
|---|---|
static Entry |
applyMods(Entry source,
ArrayList<ModificationItem> mods)
Applies a given ArrayList of modifications to an Entry object and returns it. |
String |
compactDN(String p1)
Removes spaces in a given string, including those at the string beginning, end and those following a comma character. |
ArrayList<ModificationItem> |
compareEntries(Entry a,
Entry b)
Compares two given Entry objects and returns an ArrayList with the differences (attributes that were in one of the entries and not the other). |
boolean |
differs(Attribute a,
Attribute b)
Compares two Attribute objects and returns if they are different. |
boolean |
equalsDN(String p1,
String p2)
Checks if two strings are equal. |
void |
join(Attribute a,
Attribute b)
Adds all values from the second Attribute object to the first one (if they are not already present). |
boolean |
vectorContains(Object val,
Vector<Object> v,
boolean dn)
Return true if and only if a Vector contains a value, and remove that value from the Vector. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Compare()
| Method Detail |
|---|
public void join(Attribute a,
Attribute b)
throws Exception
a - the attribute that will accept additional valuesb - the attribute whose values will be added to the first one
Exception - if a problem occurs
public boolean differs(Attribute a,
Attribute b)
throws Exception
a - first Attribute objectb - second Attribute object
true if the attributes are different, otherwise
false
Exception - if a problem occurs
public boolean vectorContains(Object val,
Vector<Object> v,
boolean dn)
val - an Object that will be searchedv - the vector whose contents will be checkeddn - determines whether strings need to be compact or not
true if the vector contains the given Object,
otherwise false
public ArrayList<ModificationItem> compareEntries(Entry a,
Entry b)
throws Exception
a - first Entry objectb - second Entry object
Exception - if a problem occurs
public static Entry applyMods(Entry source,
ArrayList<ModificationItem> mods)
source - a source Entrymods - ArrayList of modifications
public boolean equalsDN(String p1,
String p2)
p1 - first stringp2 - second string
true it the strings are equal, otherwise falsepublic String compactDN(String p1)
p1 - the String to be processed
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||