oracle.syndicate.server.cp.state
Class State
java.lang.Object
|
+--oracle.syndicate.server.cp.state.State
- public class State
- extends java.lang.Object
- Since:
- release specific (what release of product did this appear in)
Constructor Summary |
State()
|
Method Summary |
void |
beginUpdate(java.lang.String szOldState)
Initializes the internal class variable scanning the old state string passed. |
java.lang.String |
endUpdate()
Completes computation of the new subscription state using the internal class state information newSTS = new ServerTimestamp at init of scanning newDuration = timestamp at end of scanning - newSTS newMaxDLM = max (dateLastModified for all the processed items) newMResID = name of the resource of newMaxDLM // if max has not changed let's increase of elapsed time if (newMaxDLM == mdlm) { newMaxDLM = mdlm + (newSTS - stsl) newMResID = "" } new State = newSTS@@newMaxDLM@@newMResID@@newDuration |
boolean |
isUpdatedItem(long dateLastMod, java.lang.String resID)
Applys internal decision rules to tell if the current content item has been updated and has to be included in the new buildng package. |
java.lang.String |
toString()
For debug purposes |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
State
public State()
beginUpdate
public void beginUpdate(java.lang.String szOldState)
throws CPException
- Initializes the internal class variable scanning the old state string passed. This are used by the decision algorithm to determine if a specific content item is a good candidate for a new package.
isUpdatedItem
public boolean isUpdatedItem(long dateLastMod,
java.lang.String resID)
- Applys internal decision rules to tell if the current content item has been updated and has to be included in the new buildng package. Given a content item res1 having dateLastModified d1, and the old state sts1@@mdlm@@mresId@@lud the decision algorithm is isNew = false; if (res1 == mresID) { if (d1 > mdlm) { isNew = true; } } else { if (d1 > (mdlm - lud)) { isNew = true; } }
endUpdate
public java.lang.String endUpdate()
throws CPException
- Completes computation of the new subscription state using the internal class state information newSTS = new ServerTimestamp at init of scanning newDuration = timestamp at end of scanning - newSTS newMaxDLM = max (dateLastModified for all the processed items) newMResID = name of the resource of newMaxDLM // if max has not changed let's increase of elapsed time if (newMaxDLM == mdlm) { newMaxDLM = mdlm + (newSTS - stsl) newMResID = "" } new State = newSTS@@newMaxDLM@@newMResID@@newDuration
toString
public java.lang.String toString()
- For debug purposes
-
- Overrides:
toString
in class java.lang.Object
Copyright © 2001, 2003, Oracle. All rights reserved.