rapture.common.client.HttpSeriesApi Maven / Gradle / Ivy
/**
* The MIT License (MIT)
*
* Copyright (C) 2011-2016 Incapture Technologies LLC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
/**
* This file is autogenerated and any changes will be overwritten.
*/
package rapture.common.client;
import java.util.List;
import java.util.Map;
import rapture.common.api.SeriesApi;
import rapture.common.api.ScriptSeriesApi;
import rapture.common.CallingContext;
import rapture.common.model.GeneralResponse;
import rapture.common.model.BasePayload;
import rapture.common.exception.RaptureException;
import rapture.common.impl.jackson.JacksonUtil;
import com.fasterxml.jackson.core.type.TypeReference;
import org.apache.log4j.Logger;
import rapture.common.SeriesDouble;
import rapture.common.RaptureFolderInfo;
import rapture.common.SeriesRepoConfig;
import rapture.common.SeriesPoint;
import rapture.common.SeriesString;
import rapture.common.shared.series.CreateSeriesRepoPayload;
import rapture.common.shared.series.CreateSeriesPayload;
import rapture.common.shared.series.SeriesRepoExistsPayload;
import rapture.common.shared.series.SeriesExistsPayload;
import rapture.common.shared.series.GetSeriesRepoConfigPayload;
import rapture.common.shared.series.GetSeriesRepoConfigsPayload;
import rapture.common.shared.series.DeleteSeriesRepoPayload;
import rapture.common.shared.series.DeleteSeriesPayload;
import rapture.common.shared.series.DeleteSeriesByUriPrefixPayload;
import rapture.common.shared.series.AddDoubleToSeriesPayload;
import rapture.common.shared.series.AddLongToSeriesPayload;
import rapture.common.shared.series.AddStringToSeriesPayload;
import rapture.common.shared.series.AddStructureToSeriesPayload;
import rapture.common.shared.series.AddDoublesToSeriesPayload;
import rapture.common.shared.series.AddLongsToSeriesPayload;
import rapture.common.shared.series.AddStringsToSeriesPayload;
import rapture.common.shared.series.AddStructuresToSeriesPayload;
import rapture.common.shared.series.DeletePointsFromSeriesByPointKeyPayload;
import rapture.common.shared.series.DeletePointsFromSeriesPayload;
import rapture.common.shared.series.GetLastPointPayload;
import rapture.common.shared.series.GetPointsPayload;
import rapture.common.shared.series.GetPointsAfterPayload;
import rapture.common.shared.series.GetPointsAfterReversePayload;
import rapture.common.shared.series.GetPointsInRangePayload;
import rapture.common.shared.series.GetPointsAsDoublesPayload;
import rapture.common.shared.series.GetPointsAfterAsDoublesPayload;
import rapture.common.shared.series.GetPointsInRangeAsDoublesPayload;
import rapture.common.shared.series.GetPointsAsStringsPayload;
import rapture.common.shared.series.GetPointsAfterAsStringsPayload;
import rapture.common.shared.series.GetPointsInRangeAsStringsPayload;
import rapture.common.shared.series.RunSeriesScriptPayload;
import rapture.common.shared.series.RunSeriesScriptQuietPayload;
import rapture.common.shared.series.ListSeriesByUriPrefixPayload;
@SuppressWarnings("all")
public class HttpSeriesApi extends BaseHttpApi implements SeriesApi, ScriptSeriesApi {
private static final Logger log = Logger.getLogger(HttpSeriesApi.class);
public HttpSeriesApi(HttpLoginApi login) {
super(login, "series");
}
@Override
public void createSeriesRepo(CallingContext context, String seriesRepoUri, String config) {
CreateSeriesRepoPayload requestObj = new CreateSeriesRepoPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesRepoUri(seriesRepoUri);
requestObj.setConfig(config);
doRequest(requestObj, "CREATESERIESREPO", null); }
@Override
public void createSeries(CallingContext context, String seriesUri) {
CreateSeriesPayload requestObj = new CreateSeriesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
doRequest(requestObj, "CREATESERIES", null); }
private static final class SeriesRepoExistsTypeReference extends TypeReference {
}
@Override
public Boolean seriesRepoExists(CallingContext context, String seriesRepoUri) {
SeriesRepoExistsPayload requestObj = new SeriesRepoExistsPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesRepoUri(seriesRepoUri);
return doRequest(requestObj, "SERIESREPOEXISTS", new SeriesRepoExistsTypeReference()); }
private static final class SeriesExistsTypeReference extends TypeReference {
}
@Override
public Boolean seriesExists(CallingContext context, String seriesUri) {
SeriesExistsPayload requestObj = new SeriesExistsPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
return doRequest(requestObj, "SERIESEXISTS", new SeriesExistsTypeReference()); }
private static final class GetSeriesRepoConfigTypeReference extends TypeReference {
}
@Override
public SeriesRepoConfig getSeriesRepoConfig(CallingContext context, String seriesRepoUri) {
GetSeriesRepoConfigPayload requestObj = new GetSeriesRepoConfigPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesRepoUri(seriesRepoUri);
return doRequest(requestObj, "GETSERIESREPOCONFIG", new GetSeriesRepoConfigTypeReference()); }
private static final class GetSeriesRepoConfigsTypeReference extends TypeReference> {
}
@Override
public List getSeriesRepoConfigs(CallingContext context) {
GetSeriesRepoConfigsPayload requestObj = new GetSeriesRepoConfigsPayload();
requestObj.setContext(context == null ? this.getContext() : context);
return doRequest(requestObj, "GETSERIESREPOCONFIGS", new GetSeriesRepoConfigsTypeReference()); }
@Override
public void deleteSeriesRepo(CallingContext context, String seriesRepoUri) {
DeleteSeriesRepoPayload requestObj = new DeleteSeriesRepoPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesRepoUri(seriesRepoUri);
doRequest(requestObj, "DELETESERIESREPO", null); }
@Override
public void deleteSeries(CallingContext context, String seriesUri) {
DeleteSeriesPayload requestObj = new DeleteSeriesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
doRequest(requestObj, "DELETESERIES", null); }
private static final class DeleteSeriesByUriPrefixTypeReference extends TypeReference> {
}
@Override
public List deleteSeriesByUriPrefix(CallingContext context, String seriesUri) {
DeleteSeriesByUriPrefixPayload requestObj = new DeleteSeriesByUriPrefixPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
return doRequest(requestObj, "DELETESERIESBYURIPREFIX", new DeleteSeriesByUriPrefixTypeReference()); }
@Override
public void addDoubleToSeries(CallingContext context, String seriesUri, String pointKey, Double pointValue) {
AddDoubleToSeriesPayload requestObj = new AddDoubleToSeriesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setPointKey(pointKey);
requestObj.setPointValue(pointValue);
doRequest(requestObj, "ADDDOUBLETOSERIES", null); }
@Override
public void addLongToSeries(CallingContext context, String seriesUri, String pointKey, Long pointValue) {
AddLongToSeriesPayload requestObj = new AddLongToSeriesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setPointKey(pointKey);
requestObj.setPointValue(pointValue);
doRequest(requestObj, "ADDLONGTOSERIES", null); }
@Override
public void addStringToSeries(CallingContext context, String seriesUri, String pointKey, String pointValue) {
AddStringToSeriesPayload requestObj = new AddStringToSeriesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setPointKey(pointKey);
requestObj.setPointValue(pointValue);
doRequest(requestObj, "ADDSTRINGTOSERIES", null); }
@Override
public void addStructureToSeries(CallingContext context, String seriesUri, String pointKey, String pointValue) {
AddStructureToSeriesPayload requestObj = new AddStructureToSeriesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setPointKey(pointKey);
requestObj.setPointValue(pointValue);
doRequest(requestObj, "ADDSTRUCTURETOSERIES", null); }
@Override
public void addDoublesToSeries(CallingContext context, String seriesUri, List pointKeys, List pointValues) {
AddDoublesToSeriesPayload requestObj = new AddDoublesToSeriesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setPointKeys(pointKeys);
requestObj.setPointValues(pointValues);
doRequest(requestObj, "ADDDOUBLESTOSERIES", null); }
@Override
public void addLongsToSeries(CallingContext context, String seriesUri, List pointKeys, List pointValues) {
AddLongsToSeriesPayload requestObj = new AddLongsToSeriesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setPointKeys(pointKeys);
requestObj.setPointValues(pointValues);
doRequest(requestObj, "ADDLONGSTOSERIES", null); }
@Override
public void addStringsToSeries(CallingContext context, String seriesUri, List pointKeys, List pointValues) {
AddStringsToSeriesPayload requestObj = new AddStringsToSeriesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setPointKeys(pointKeys);
requestObj.setPointValues(pointValues);
doRequest(requestObj, "ADDSTRINGSTOSERIES", null); }
@Override
public void addStructuresToSeries(CallingContext context, String seriesUri, List pointKeys, List pointValues) {
AddStructuresToSeriesPayload requestObj = new AddStructuresToSeriesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setPointKeys(pointKeys);
requestObj.setPointValues(pointValues);
doRequest(requestObj, "ADDSTRUCTURESTOSERIES", null); }
@Override
public void deletePointsFromSeriesByPointKey(CallingContext context, String seriesUri, List pointKeys) {
DeletePointsFromSeriesByPointKeyPayload requestObj = new DeletePointsFromSeriesByPointKeyPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setPointKeys(pointKeys);
doRequest(requestObj, "DELETEPOINTSFROMSERIESBYPOINTKEY", null); }
@Override
public void deletePointsFromSeries(CallingContext context, String seriesUri) {
DeletePointsFromSeriesPayload requestObj = new DeletePointsFromSeriesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
doRequest(requestObj, "DELETEPOINTSFROMSERIES", null); }
private static final class GetLastPointTypeReference extends TypeReference {
}
@Override
public SeriesPoint getLastPoint(CallingContext context, String seriesUri) {
GetLastPointPayload requestObj = new GetLastPointPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
return doRequest(requestObj, "GETLASTPOINT", new GetLastPointTypeReference()); }
private static final class GetPointsTypeReference extends TypeReference> {
}
@Override
public List getPoints(CallingContext context, String seriesUri) {
GetPointsPayload requestObj = new GetPointsPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
return doRequest(requestObj, "GETPOINTS", new GetPointsTypeReference()); }
private static final class GetPointsAfterTypeReference extends TypeReference> {
}
@Override
public List getPointsAfter(CallingContext context, String seriesUri, String startColumn, int maxNumber) {
GetPointsAfterPayload requestObj = new GetPointsAfterPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setStartColumn(startColumn);
requestObj.setMaxNumber(maxNumber);
return doRequest(requestObj, "GETPOINTSAFTER", new GetPointsAfterTypeReference()); }
private static final class GetPointsAfterReverseTypeReference extends TypeReference> {
}
@Override
public List getPointsAfterReverse(CallingContext context, String seriesUri, String startColumn, int maxNumber) {
GetPointsAfterReversePayload requestObj = new GetPointsAfterReversePayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setStartColumn(startColumn);
requestObj.setMaxNumber(maxNumber);
return doRequest(requestObj, "GETPOINTSAFTERREVERSE", new GetPointsAfterReverseTypeReference()); }
private static final class GetPointsInRangeTypeReference extends TypeReference> {
}
@Override
public List getPointsInRange(CallingContext context, String seriesUri, String startColumn, String endColumn, int maxNumber) {
GetPointsInRangePayload requestObj = new GetPointsInRangePayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setStartColumn(startColumn);
requestObj.setEndColumn(endColumn);
requestObj.setMaxNumber(maxNumber);
return doRequest(requestObj, "GETPOINTSINRANGE", new GetPointsInRangeTypeReference()); }
private static final class GetPointsAsDoublesTypeReference extends TypeReference> {
}
@Override
public List getPointsAsDoubles(CallingContext context, String seriesUri) {
GetPointsAsDoublesPayload requestObj = new GetPointsAsDoublesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
return doRequest(requestObj, "GETPOINTSASDOUBLES", new GetPointsAsDoublesTypeReference()); }
private static final class GetPointsAfterAsDoublesTypeReference extends TypeReference> {
}
@Override
public List getPointsAfterAsDoubles(CallingContext context, String seriesUri, String startColumn, int maxNumber) {
GetPointsAfterAsDoublesPayload requestObj = new GetPointsAfterAsDoublesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setStartColumn(startColumn);
requestObj.setMaxNumber(maxNumber);
return doRequest(requestObj, "GETPOINTSAFTERASDOUBLES", new GetPointsAfterAsDoublesTypeReference()); }
private static final class GetPointsInRangeAsDoublesTypeReference extends TypeReference> {
}
@Override
public List getPointsInRangeAsDoubles(CallingContext context, String seriesUri, String startColumn, String endColumn, int maxNumber) {
GetPointsInRangeAsDoublesPayload requestObj = new GetPointsInRangeAsDoublesPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setStartColumn(startColumn);
requestObj.setEndColumn(endColumn);
requestObj.setMaxNumber(maxNumber);
return doRequest(requestObj, "GETPOINTSINRANGEASDOUBLES", new GetPointsInRangeAsDoublesTypeReference()); }
private static final class GetPointsAsStringsTypeReference extends TypeReference> {
}
@Override
public List getPointsAsStrings(CallingContext context, String seriesUri) {
GetPointsAsStringsPayload requestObj = new GetPointsAsStringsPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
return doRequest(requestObj, "GETPOINTSASSTRINGS", new GetPointsAsStringsTypeReference()); }
private static final class GetPointsAfterAsStringsTypeReference extends TypeReference> {
}
@Override
public List getPointsAfterAsStrings(CallingContext context, String seriesUri, String startColumn, int maxNumber) {
GetPointsAfterAsStringsPayload requestObj = new GetPointsAfterAsStringsPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setStartColumn(startColumn);
requestObj.setMaxNumber(maxNumber);
return doRequest(requestObj, "GETPOINTSAFTERASSTRINGS", new GetPointsAfterAsStringsTypeReference()); }
private static final class GetPointsInRangeAsStringsTypeReference extends TypeReference> {
}
@Override
public List getPointsInRangeAsStrings(CallingContext context, String seriesUri, String startColumn, String endColumn, int maxNumber) {
GetPointsInRangeAsStringsPayload requestObj = new GetPointsInRangeAsStringsPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setSeriesUri(seriesUri);
requestObj.setStartColumn(startColumn);
requestObj.setEndColumn(endColumn);
requestObj.setMaxNumber(maxNumber);
return doRequest(requestObj, "GETPOINTSINRANGEASSTRINGS", new GetPointsInRangeAsStringsTypeReference()); }
private static final class RunSeriesScriptTypeReference extends TypeReference> {
}
@Override
public List runSeriesScript(CallingContext context, String scriptContent, List arguments) {
RunSeriesScriptPayload requestObj = new RunSeriesScriptPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setScriptContent(scriptContent);
requestObj.setArguments(arguments);
return doRequest(requestObj, "RUNSERIESSCRIPT", new RunSeriesScriptTypeReference()); }
@Override
public void runSeriesScriptQuiet(CallingContext context, String scriptContent, List arguments) {
RunSeriesScriptQuietPayload requestObj = new RunSeriesScriptQuietPayload();
requestObj.setContext(context == null ? this.getContext() : context);
requestObj.setScriptContent(scriptContent);
requestObj.setArguments(arguments);
doRequest(requestObj, "RUNSERIESSCRIPTQUIET", null); }
private static final class ListSeriesByUriPrefixTypeReference extends TypeReference
© 2015 - 2025 Weber Informatics LLC | Privacy Policy