org.fcrepo.server.journal.entry
Class JournalEntryContext

java.lang.Object
  extended by org.fcrepo.server.journal.entry.JournalEntryContext
All Implemented Interfaces:
Context, RecoveryContext

public class JournalEntryContext
extends Object
implements RecoveryContext

A fully writable context that can be used when recovering entries from a Journal.

Author:
Jim Blake

Field Summary
 
Fields inherited from interface org.fcrepo.server.Context
FEDORA_AUX_SUBJECT_ATTRIBUTES
 
Constructor Summary
JournalEntryContext()
          Create an empty context.
JournalEntryContext(Context source)
          A "copy constructor" that creates a writable context from one that might be read-only.
 
Method Summary
 Iterator actionAttributes()
           
 Iterator environmentAttributes()
           
 boolean equals(Object obj)
           
 MultiValueMap getActionAttributes()
           
 String getActionValue(String name)
           
 String[] getActionValues(String name)
           
 MultiValueMap getEnvironmentAttributes()
           
 String getEnvironmentValue(String name)
           
 String[] getEnvironmentValues(String name)
           
 boolean getNoOp()
           
 String getPassword()
           
 MultiValueMap getRecoveryAttributes()
           
 Iterator getRecoveryNames()
          Get the names of all recovery attributes whose values are defined in this context.
 String getRecoveryValue(String attribute)
          Get the first value for a recovery attribute, or null if no such value exists in this context.
 String[] getRecoveryValues(String attribute)
          Get all values for a recovery attribute, or an empty array if no values exist for the attribute in this context.
 MultiValueMap getResourceAttributes()
           
 String getResourceValue(String name)
           
 String[] getResourceValues(String name)
           
 MultiValueMap getSubjectAttributes()
           
 String getSubjectValue(String name)
           
 String[] getSubjectValues(String name)
           
 int hashCode()
           
 int nActionValues(String name)
           
 int nEnvironmentValues(String name)
           
 Date now()
           
 int nResourceValues(String name)
           
 int nSubjectValues(String name)
           
 Iterator resourceAttributes()
           
 void setActionAttributes(MultiValueMap actionAttributes)
           
 void setEnvironmentAttributes(MultiValueMap environmentAttributes)
           
 void setNoOp(boolean noOp)
           
 void setNow(Date now)
           
 void setPassword(String password)
           
 void setRecoveryAttributes(MultiValueMap recoveryAttributes)
           
 void setRecoveryValue(String attribute, String value)
           
 void setRecoveryValues(String attribute, String[] values)
           
 void setResourceAttributes(MultiValueMap resourceAttributes)
           
 void setSubjectAttributes(MultiValueMap subjectAttributes)
           
 Iterator subjectAttributes()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

JournalEntryContext

public JournalEntryContext()
Create an empty context.


JournalEntryContext

public JournalEntryContext(Context source)
A "copy constructor" that creates a writable context from one that might be read-only.

Method Detail

getEnvironmentAttributes

public MultiValueMap getEnvironmentAttributes()
Specified by:
getEnvironmentAttributes in interface Context

environmentAttributes

public Iterator environmentAttributes()
Specified by:
environmentAttributes in interface Context

nEnvironmentValues

public int nEnvironmentValues(String name)
Specified by:
nEnvironmentValues in interface Context

getEnvironmentValue

public String getEnvironmentValue(String name)
Specified by:
getEnvironmentValue in interface Context

getEnvironmentValues

public String[] getEnvironmentValues(String name)
Specified by:
getEnvironmentValues in interface Context

subjectAttributes

public Iterator subjectAttributes()
Specified by:
subjectAttributes in interface Context

nSubjectValues

public int nSubjectValues(String name)
Specified by:
nSubjectValues in interface Context

getSubjectValue

public String getSubjectValue(String name)
Specified by:
getSubjectValue in interface Context

getSubjectValues

public String[] getSubjectValues(String name)
Specified by:
getSubjectValues in interface Context

actionAttributes

public Iterator actionAttributes()
Specified by:
actionAttributes in interface Context

nActionValues

public int nActionValues(String name)
Specified by:
nActionValues in interface Context

getActionValue

public String getActionValue(String name)
Specified by:
getActionValue in interface Context

getActionValues

public String[] getActionValues(String name)
Specified by:
getActionValues in interface Context

resourceAttributes

public Iterator resourceAttributes()
Specified by:
resourceAttributes in interface Context

nResourceValues

public int nResourceValues(String name)
Specified by:
nResourceValues in interface Context

getResourceValue

public String getResourceValue(String name)
Specified by:
getResourceValue in interface Context

getResourceValues

public String[] getResourceValues(String name)
Specified by:
getResourceValues in interface Context

setActionAttributes

public void setActionAttributes(MultiValueMap actionAttributes)
Specified by:
setActionAttributes in interface Context

setResourceAttributes

public void setResourceAttributes(MultiValueMap resourceAttributes)
Specified by:
setResourceAttributes in interface Context

getPassword

public String getPassword()
Specified by:
getPassword in interface Context

now

public Date now()
Specified by:
now in interface Context

getNoOp

public boolean getNoOp()
Specified by:
getNoOp in interface Context

getRecoveryNames

public Iterator getRecoveryNames()
Description copied from interface: RecoveryContext
Get the names of all recovery attributes whose values are defined in this context.

Specified by:
getRecoveryNames in interface RecoveryContext

getRecoveryValue

public String getRecoveryValue(String attribute)
Description copied from interface: RecoveryContext
Get the first value for a recovery attribute, or null if no such value exists in this context.

Specified by:
getRecoveryValue in interface RecoveryContext

getRecoveryValues

public String[] getRecoveryValues(String attribute)
Description copied from interface: RecoveryContext
Get all values for a recovery attribute, or an empty array if no values exist for the attribute in this context.

Specified by:
getRecoveryValues in interface RecoveryContext

toString

public String toString()
Specified by:
toString in interface Context
Overrides:
toString in class Object

getActionAttributes

public MultiValueMap getActionAttributes()

setEnvironmentAttributes

public void setEnvironmentAttributes(MultiValueMap environmentAttributes)

setSubjectAttributes

public void setSubjectAttributes(MultiValueMap subjectAttributes)

getSubjectAttributes

public MultiValueMap getSubjectAttributes()

getResourceAttributes

public MultiValueMap getResourceAttributes()

setRecoveryAttributes

public void setRecoveryAttributes(MultiValueMap recoveryAttributes)

getRecoveryAttributes

public MultiValueMap getRecoveryAttributes()

setRecoveryValue

public void setRecoveryValue(String attribute,
                             String value)

setRecoveryValues

public void setRecoveryValues(String attribute,
                              String[] values)

setNoOp

public void setNoOp(boolean noOp)

setPassword

public void setPassword(String password)

setNow

public void setNow(Date now)

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2012 DuraSpace. All Rights Reserved.