X-Git-Url: http://jsfdemo.indexdata.com/?a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fcom%2Findexdata%2Fmkjsf%2Fpazpar2%2Fcommands%2FRecordCommand.java;h=93f7782d13549b40f446f7a66552d102fab3dc37;hb=7689ef2cae342cd80a0e504b2d68bde4f5348850;hp=78d192eea239207e896b83f24bc945a57ee764aa;hpb=ccb28ae8d5d46d29c40bd8b1637522c212b80636;p=mkjsf-moved-to-github.git diff --git a/src/main/java/com/indexdata/mkjsf/pazpar2/commands/RecordCommand.java b/src/main/java/com/indexdata/mkjsf/pazpar2/commands/RecordCommand.java index 78d192e..93f7782 100644 --- a/src/main/java/com/indexdata/mkjsf/pazpar2/commands/RecordCommand.java +++ b/src/main/java/com/indexdata/mkjsf/pazpar2/commands/RecordCommand.java @@ -1,8 +1,10 @@ package com.indexdata.mkjsf.pazpar2.commands; +import com.indexdata.mkjsf.pazpar2.commands.sp.RecordCommandSp; +import com.indexdata.mkjsf.pazpar2.commands.sp.ServiceProxyCommand; import com.indexdata.mkjsf.pazpar2.state.StateManager; -public class RecordCommand extends Pazpar2Command { +public class RecordCommand extends Pazpar2Command implements ServiceProxyCommand { private static final long serialVersionUID = 2817539422114569506L; @@ -16,7 +18,55 @@ public class RecordCommand extends Pazpar2Command { public String getId () { return getParameterValue("id"); - } + } + + public void setOffset (String offset) { + setParameter(new CommandParameter("offset","=",offset)); + } + + public String getOffset () { + return getParameterValue("offset"); + } + + public void setChecksum (String checksum) { + setParameter(new CommandParameter("checksum","=",checksum)); + } + + public String getChecksum () { + return getParameterValue("checksum"); + } + + public void setNativesyntax (String nativesyntax) { + setParameterInState(new CommandParameter("nativesyntax","=",nativesyntax)); + } + + public String getNativesyntax () { + return getParameterValue("nativesyntax"); + } + + public void setSyntax (String syntax) { + setParameterInState(new CommandParameter("syntax","=",syntax)); + } + + public String getSyntax () { + return getParameterValue("syntax"); + } + + public void setEsn (String esn) { + setParameter(new CommandParameter("esn","=",esn)); + } + + public String getEsn () { + return getParameterValue("esn"); + } + + public void setBinary (String binary) { + setParameter(new CommandParameter("binary","=",binary)); + } + + public String getBinary () { + return getParameterValue("binary"); + } @Override public RecordCommand copy () { @@ -26,4 +76,13 @@ public class RecordCommand extends Pazpar2Command { } return newCommand; } + + + /** + * Returns a record command object with Service Proxy extension parameters + * + */ + public RecordCommandSp getSp () { + return new RecordCommandSp(this); + } }