|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectanonymizer.Anonymizer
public abstract class Anonymizer
An abstract class for anonymization methods. Basic functions include reading data from a source and outputtung the results.
Every class that extends Anonymizer should implement methods for (1) creating an equivalence table, (2) creating an anonymized records table, (3) insertion into equivalence table, (3) insertion into anonymized records table and obviously, (5) anonymization.
Field Summary | |
---|---|
protected AnonRecordTable |
anonTable
Current working anonRecords table |
protected Configuration |
conf
Configuration object |
protected EquivalenceTable |
eqTable
Current working equivalence table |
protected SQLWrapper |
sqlwrapper
Embedded database connection object |
protected int |
suppressionThreshold
Suppression threshold (required only if the method allows suppression) |
Constructor Summary | |
---|---|
Anonymizer(Configuration conf)
Class constructor |
Method Summary | |
---|---|
abstract void |
anonymize()
Anonymizes the input |
static void |
anonymizeDataset(Configuration conf)
|
static void |
anonymizeDataset(java.lang.String[] args)
Anonymize an input based on the specified argument list. |
protected abstract AnonRecordTable |
createAnonRecordsTable(java.lang.String tableName)
Creates the anonymized records table |
protected abstract EquivalenceTable |
createEquivalenceTable(java.lang.String tableName)
Creates the equivalence table |
private void |
generateDistributions()
Generates quasi-identifier distributions for each quasi-identifier |
protected abstract void |
insertTupleToAnonTable(java.lang.String[] vals,
long eid)
Insert a tuple to the anonRecords table |
protected abstract long |
insertTupleToEquivalenceTable(java.lang.String[] vals)
Insert a tuple to the equivalence table |
protected java.util.LinkedList<java.lang.Long> |
isReadyForSuppression(java.lang.String anonRecordTable)
Checks if the generalized data is ready for suppression |
static void |
main(java.lang.String[] args)
|
void |
outputResults_Anatomy()
Output the results and close the connection to the database |
void |
outputResults_GenVals()
Output the results and close the connection to the database |
void |
outputResults_GenValsDist()
Output the results and close the connection to the database |
void |
outputResults()
Output the results and close the connection to the database |
void |
readData()
Read input data |
protected void |
suppressEquivalences(java.util.LinkedList<java.lang.Long> suppressionList)
Suppress the equivalences with provided IDs. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected Configuration conf
protected EquivalenceTable eqTable
protected AnonRecordTable anonTable
protected SQLWrapper sqlwrapper
protected int suppressionThreshold
Constructor Detail |
---|
public Anonymizer(Configuration conf)
Method Detail |
---|
protected abstract EquivalenceTable createEquivalenceTable(java.lang.String tableName)
tableName
- Name of the table
protected abstract AnonRecordTable createAnonRecordsTable(java.lang.String tableName)
tableName
- Name of the table
protected abstract long insertTupleToEquivalenceTable(java.lang.String[] vals) throws java.lang.Exception
vals
- All values of the tuple to be inserted (as read from the source, i.e., before any generalization)
java.lang.Exception
protected abstract void insertTupleToAnonTable(java.lang.String[] vals, long eid) throws java.lang.Exception
vals
- All values of the tuple to be inserted (as read from the source, i.e., before any generalization)eid
- Equivalence id of the equivalence to which the tuple belongs
java.lang.Exception
public void readData() throws java.lang.Exception
java.lang.Exception
public abstract void anonymize() throws java.lang.Exception
java.lang.Exception
protected java.util.LinkedList<java.lang.Long> isReadyForSuppression(java.lang.String anonRecordTable) throws java.lang.Exception
anonRecordTable
- Name of the current anonymization record table
java.lang.Exception
protected void suppressEquivalences(java.util.LinkedList<java.lang.Long> suppressionList)
suppressionList
- IDs of equivalences to be suppressedpublic void outputResults() throws java.lang.Exception
java.lang.Exception
public void outputResults_GenVals() throws java.lang.Exception
java.lang.Exception
public void outputResults_GenValsDist() throws java.lang.Exception
java.lang.Exception
private void generateDistributions() throws java.lang.Exception
java.lang.Exception
public void outputResults_Anatomy() throws java.lang.Exception
java.lang.Exception
public static void anonymizeDataset(java.lang.String[] args) throws java.lang.Exception
args
- list of program arguments.
java.lang.Exception
public static void anonymizeDataset(Configuration conf) throws java.lang.Exception
java.lang.Exception
public static void main(java.lang.String[] args)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |